{"id":37488083,"url":"https://github.com/2chevskii/dot-not","last_synced_at":"2026-01-16T07:34:15.570Z","repository":{"id":57139158,"uuid":"247824413","full_name":"2chevskii/dot-not","owner":"2chevskii","description":"Dot notation library based on recursion","archived":false,"fork":false,"pushed_at":"2020-03-25T09:46:45.000Z","size":76,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-25T07:29:43.434Z","etag":null,"topics":["dot-notation","library","object-manipulation"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/@rustworkshop/dot-not","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/2chevskii.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-03-16T21:58:39.000Z","updated_at":"2020-04-12T17:16:04.000Z","dependencies_parsed_at":"2022-09-03T16:02:14.962Z","dependency_job_id":null,"html_url":"https://github.com/2chevskii/dot-not","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/2chevskii/dot-not","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/2chevskii%2Fdot-not","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/2chevskii%2Fdot-not/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/2chevskii%2Fdot-not/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/2chevskii%2Fdot-not/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/2chevskii","download_url":"https://codeload.github.com/2chevskii/dot-not/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/2chevskii%2Fdot-not/sbom","scorecard":{"id":2898,"data":{"date":"2025-08-11","repo":{"name":"github.com/2chevskii/dot-not","commit":"5f9f2bc7c45ebdb4e1ff3bbf053c2399b7952256"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.1,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:29: update your workflow using https://app.stepsecurity.io/secureworkflow/2chevskii/dot-not/build.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:31: update your workflow using https://app.stepsecurity.io/secureworkflow/2chevskii/dot-not/build.yml/master?enable=pin","Warn: npmCommand not pinned by hash: .github/workflows/build.yml:36","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 npmCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/build.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":0,"reason":"Project has not signed or included provenance with any releases.","details":["Warn: release artifact v1.0.0 not signed: https://api.github.com/repos/2chevskii/dot-not/releases/24829574","Warn: release artifact v1.0.0 does not have provenance: https://api.github.com/repos/2chevskii/dot-not/releases/24829574"],"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-14T12:56:51.703Z","repository_id":57139158,"created_at":"2025-08-14T12:56:51.703Z","updated_at":"2025-08-14T12:56:51.703Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28478047,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-16T06:30:42.265Z","status":"ssl_error","status_checked_at":"2026-01-16T06:30:16.248Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dot-notation","library","object-manipulation"],"created_at":"2026-01-16T07:34:14.934Z","updated_at":"2026-01-16T07:34:15.561Z","avatar_url":"https://github.com/2chevskii.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# DOT-NOT\n\n[![Logo](logo.png)][repo]\n\n\u003e Another fucking dot notation lib in js?!\n\n## Installation\n\n`npm i @rustworkshop/dot-not`\n\n## Usage\n\n### Import module\n\n```js\nimport dotnot from '@rustworkshop/dot-not'\n// or\nconst dotnot = require('@rustworkshop/dot-not')\n// destructure import works properly only in TypeScript (tested in NodeJS/VSCode)\nimport { get, set, copy, move, remove, parse } from '@rustworkshop/dot-not'\n```\n\n### Paths\n\nThis package uses own parser for dot-notation paths handling, it has some rules\n\n  - Nested properties are separated by dot:\n\n    ```js\n    'foo.bar.baz' =\u003e [ 'foo', 'bar', 'baz' ] =\u003e  { foo: { bar: { baz: \u003csome value\u003e } } }\n    ```\n\n  - You can escape dot using backslash (`\\`):\n\n    ```js\n    'foo\\\\.bar.baz' =\u003e [ 'foo.bar', 'baz' ]\n    ```\n\n  - Backslashes are only interpreted as escape characters while they are located before other backslashes or dots\n\n    ```js\n    'foo\\\\bar' == 'foo\\\\\\\\bar' =\u003e [ 'foo\\\\bar' ]\n    'foo.\\\\' =\u003e [ 'foo', '\\\\' ]\n    ```\n\n  - You can escape backslash by using backslash:\n\n    ```js\n    'foo\\\\\\\\.bar.baz' =\u003e [ 'foo\\\\', 'bar', 'baz' ]\n    ```\n\n  - Empty path segments are interpreted as property with '' key\n\n    ```js\n    '' =\u003e [ '' ] =\u003e { '': \u003csome value\u003e }\n    ```\n\n    ```js\n    '.' =\u003e [ '', '' ] =\u003e { '': { '': \u003csome value\u003e } }\n    ```\n\n### Receiving values\n\n\u003eFunction `get` allows you to get values from objects\n\n```ts\nfunction get (object: object, path: string, defaultValue?: any): any\n```\n\n```js\nconst object = { hello: 'world' };\n\nconsole.log(get(object, 'hello')); // 'world'\n```\n\n\u003eWhen supplied, 'defaultValue' will be written into target property, if it does not exist\n\n```js\nconst object = { hello: 'world' };\n\nconsole.log(get(object, 'foo.bar', 42)); // 42\nconsole.log(object); // { hello: 'world', foo: { bar: 42 } }\n\n```\n\n**Warning:** while writing a default value to the object, it will overwrite all the existing properties that are encountered, if they are not objects or arrays\n\n```js\nconst object = { hello: 'world' };\n\nconsole.log(get(object, 'hello.bar', 42)); // 42\nconsole.log(object); // { hello: { bar: 42 } }\n```\n\n### Setting values\n\nFunction `set` allows you to set values for object properties\n\n```ts\nfunction set (object: object, path: string, value: any, force?: boolean): boolean\n```\n\n```js\nconst object = {};\n\nconsole.log(set(object, 'foo\\\\.bar', 42)); // true\n\nconsole.log(object); // { 'foo.bar': 42 }\n```\n\n\u003eBy default, `force` argument is set to `true`, so like with `get` function, it will overwrite all encountered properties to match the structure, you can set it to `false`, so your objects are kept intact (function will return `false` as well)\n\n```js\nconst object = {\n    foo: 55\n};\n\nconsole.log(set(object, 'foo\\\\.bar', 42, false)); //true\n\nconsole.log(object); // { 'foo.bar': 42, foo: 55 }\n\nconsole.log(set(object, 'foo.bar', 55, false)); // false\n\nconsole.log(object); // { 'foo.bar': 42, foo: 55 }\n\nconsole.log(set(object, 'foo.bar', 55, true)); // true\n\nconsole.log(object); // { 'foo.bar': 42, foo: { bar: 55 } }\n```\n\n### Checking for property existence\n\nFunction `has` will simply check, if property exists in the object\n\n```ts\nfunction has (object: object, path: string, type?: string): boolean\n```\n\n```js\nconst object = {\n    foo: {\n        foo: 55,\n        bar: undefined,\n        baz: [\n            'hello',\n            'world'\n        ]\n    }\n};\n\nconsole.log(has(object, 'foo')); // true\n\nconsole.log(has(object, 'foo.bar')); // true\n\nconsole.log(has(object, 'foo.baz.1')); // true\n\nconsole.log(has(object, 'foo.baz.2')); // false\n\n```\n\n\u003eYou can also check if the property matches the type you specify\n\n```js\nconst object = {\n    foo: {\n        foo: 55,\n        bar: undefined,\n        baz: [\n            'hello',\n            'world'\n        ]\n    }\n};\n\nconsole.log(has(object, 'foo.foo')); // true\n\nconsole.log(has(object, 'foo.foo', 'string')); // false\n```\n\n### Copying properties\n\nFunction `copy` allows you to copy value from one property to another (possibly - to another object)\n\n```ts\nfunction copy (sourceObject: object, sourcePath: string, targetPath: string, targetObject?: object): boolean\n```\n\n**Warning:** library does not perform 'deep' copy of objects! That means [arrays] and {objects} will be just a 'link' to the original and will mutate with it\n\n\u003eReturns `false`, if there is nothing to copy from, otherwise - true. Overwrites the target property!\n\n```js\nconst object = {\n    foo: 42\n};\n\ncopy(object, 'foo', 'bar.foo'); // when 4th argument (target object) is not supplied, it will be the source object itself\n\nconsole.log(object); // { foo: 42, bar: { foo: 42 } }\n```\n\n### Moving properties\n\nFunction `move` allows you to remove property from one object, and add it to another\n\n```ts\nfunction move (sourceObject: object, sourcePath: string, targetPath: string, targetObject?: object): boolean\n```\n\n```js\nconst object = {\n    foo: 42\n};\n\ncopy(object, 'foo', 'bar.foo'); // when 4th argument (target object) is not supplied, it will be the source object itself\n\nconsole.log(object); // { bar: { foo: 42 } }\n```\n\n### Deleting properties\n\nFunction `remove` allows you to delete object's property\n\n```ts\nfunction remove (object: object, path: string): boolean\n```\n\n```js\nconst object = { foo: 'bar' };\n\nremove(object, 'foo');\n\nconsole.log(object); // { }\n```\n\n### Parsing dotty paths\n\nFunction `parse` exposes parser used in the library\n\n```ts\nfunction parse (path: string): string[]\n```\n\n```js\nconsole.log(parse('foo.bar..baz\\\\.\\\\\\\\.\\\\.')); // [ 'foo', 'bar', '', 'baz.', '\\\\', '.' ]\n```\n\n## Building\n\n### Requirements\n\n  - [PowerShell Core][pscore] `\u003e=7.0.0`\n  - [NodeJS]\n\n### Steps\n\n  - Clone the source repository\n\n    `git clone https://github.com/2chevskii/dot-not.git`\n\n  - Install all the dependencies\n\n    `npm install`\n\n  - Build the project (with or without `tslib` imports, depends on your wish)\n\n    `npm run build` \u003c=\u003e `npm run build -- -NoTSLib`\n\n  - Optionally - generate a tarball\n\n    `npm pack`\n\n[pscore]: https://github.com/PowerShell/PowerShell/releases\n[nodejs]: https://nodejs.org/en/download/current/\n[repo]: https://github.com/2chevskii/dot-not.git\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F2chevskii%2Fdot-not","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F2chevskii%2Fdot-not","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F2chevskii%2Fdot-not/lists"}