You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## Comparisons to other libs, or _"the list of shame"_
65
+
66
+
These are just a few of the duplicate libraries on NPM.
67
+
68
+
-[bury][] fails all of the tests. I even wrapped it to have it return the object instead of the value, but with all of that work it still fails the vast majority of tests.
69
+
-[deep-get-set][] fails 22 of 26 unit tests.
70
+
-[deep-object][] fails 25 of 26 unit tests, completely butchered given objects.
71
+
-[deep-property][] fails 17 of 26 unit tests.
72
+
-[deep-set][] fails 13 of 26 unit tests.
73
+
-[deephas][] fails 17 of 26 unit tests.
74
+
-[dot-prop][] fails 9 of 26 unit tests.
75
+
-[dot2val][] fails 17 of 26 unit tests.
76
+
-[es5-dot-prop][] fails 15 of 26 unit tests.
77
+
-[getsetdeep][] fails all unit tests due to `this` being used improperly in the methods. I was able to patch it by binding the (plain) object to the methods, but it still fails 17 of 26 unit tests.
78
+
-[lodash.set][] fails 11 of 26 unit tests.
79
+
-[object-path-set][] fails 12 of 26 unit tests.
80
+
-[object-path][] fails 16 of 26 unit tests.
81
+
-[object-set][] fails 13 of 26 unit tests.
82
+
-[set-nested-prop][] fails 24 of 26 unit tests.
83
+
-[setvalue][] (this library is almost identical to a previous version of this library)
84
+
- Many dozens of others
85
+
86
+
**Others that do the same thing, but use a completely different API**
87
+
88
+
-[deep-set-in][]
89
+
-[set-deep][]
90
+
-[set-deep-prop][]
91
+
-[bury][]
92
+
- Many dozens of others
93
+
94
+
73
95
## History
74
96
97
+
### v3.0.0
98
+
99
+
- Added support for a custom `split` function to be passed on the options.
100
+
- Removed support for splitting on brackets, since a [custom function][split-string] can be passed to do this now.
101
+
75
102
### v2.0.0
76
103
77
104
- Adds support for escaping with double or single quotes. See [escaping](#escaping) for examples.
> Create nested values and any intermediaries using dot notation (`'a.b.c'`) paths.
4
4
5
+
Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support.
## Comparisons to other libs, or _"the list of shame"_
122
+
123
+
These are just a few of the duplicate libraries on NPM.
124
+
125
+
*[bury](https://github.com/kalmbach/bury) fails all of the tests. I even wrapped it to have it return the object instead of the value, but with all of that work it still fails the vast majority of tests.
126
+
*[deep-get-set](https://github.com/acstll/deep-get-set) fails 22 of 26 unit tests.
127
+
*[deep-object](https://github.com/ayushgp/deep-object) fails 25 of 26 unit tests, completely butchered given objects.
128
+
*[deep-property](https://github.com/mikattack/node-deep-property) fails 17 of 26 unit tests.
129
+
*[deep-set](https://github.com/klaemo/deep-set) fails 13 of 26 unit tests.
130
+
*[deephas](https://github.com/sharpred/deepHas) fails 17 of 26 unit tests.
131
+
*[dot-prop](https://github.com/sindresorhus/dot-prop) fails 9 of 26 unit tests.
132
+
*[dot2val](https://github.com/yangg/dot2val) fails 17 of 26 unit tests.
133
+
*[es5-dot-prop](https://github.com/sindresorhus/dot-prop) fails 15 of 26 unit tests.
134
+
*[getsetdeep](https://github.com/bevry/getsetdeep) fails all unit tests due to `this` being used improperly in the methods. I was able to patch it by binding the (plain) object to the methods, but it still fails 17 of 26 unit tests.
135
+
*[lodash.set](https://lodash.com/) fails 11 of 26 unit tests.
136
+
*[object-path-set](https://github.com/skratchdot/object-path-set) fails 12 of 26 unit tests.
137
+
*[object-path](https://github.com/mariocasciaro/object-path) fails 16 of 26 unit tests.
138
+
*[object-set](https://github.com/gearcase/object-set) fails 13 of 26 unit tests.
139
+
*[set-nested-prop](https://github.com/tiaanduplessis/set-nested-prop) fails 24 of 26 unit tests.
140
+
*[setvalue](https://github.com/blakeembrey/setvalue) (this library is almost identical to a previous version of this library)
141
+
* Many dozens of others
142
+
143
+
**Others that do the same thing, but use a completely different API**
* Added support for a custom `split` function to be passed on the options.
156
+
* Removed support for splitting on brackets, since a [custom function](https://github.com/jonschlinkert/split-string) can be passed to do this now.
157
+
86
158
### v2.0.0
87
159
88
160
* Adds support for escaping with double or single quotes. See [escaping](#escaping) for examples.
@@ -92,30 +164,26 @@ If there are any regressions please create a [bug report](../../issues/new). Tha
92
164
93
165
## About
94
166
95
-
### Related projects
167
+
<details>
168
+
<summary><strong>Contributing</strong></summary>
96
169
97
-
*[assign-value](https://www.npmjs.com/package/assign-value): Assign a value or extend a deeply nested property of an object using object path… [more](https://github.com/jonschlinkert/assign-value) | [homepage](https://github.com/jonschlinkert/assign-value"Assign a value or extend a deeply nested property of an object using object path notation.")
98
-
*[get-value](https://www.npmjs.com/package/get-value): Use property paths (`a.b.c`) to get a nested value from an object. | [homepage](https://github.com/jonschlinkert/get-value"Use property paths (`a.b.c`) to get a nested value from an object.")
99
-
*[has-value](https://www.npmjs.com/package/has-value): Returns true if a value exists, false if empty. Works with deeply nested values using… [more](https://github.com/jonschlinkert/has-value) | [homepage](https://github.com/jonschlinkert/has-value"Returns true if a value exists, false if empty. Works with deeply nested values using object paths.")
100
-
*[merge-value](https://www.npmjs.com/package/merge-value): Similar to assign-value but deeply merges object values or nested values using object path/dot notation. | [homepage](https://github.com/jonschlinkert/merge-value"Similar to assign-value but deeply merges object values or nested values using object path/dot notation.")
101
-
*[omit-value](https://www.npmjs.com/package/omit-value): Omit properties from an object or deeply nested property of an object using object path… [more](https://github.com/jonschlinkert/omit-value) | [homepage](https://github.com/jonschlinkert/omit-value"Omit properties from an object or deeply nested property of an object using object path notation.")
102
-
*[set-value](https://www.npmjs.com/package/set-value): Create nested values and any intermediaries using dot notation (`'a.b.c'`) paths. | [homepage](https://github.com/jonschlinkert/set-value"Create nested values and any intermediaries using dot notation (`'a.b.c'`) paths.")
103
-
*[union-value](https://www.npmjs.com/package/union-value): Set an array of unique values as the property of an object. Supports setting deeply… [more](https://github.com/jonschlinkert/union-value) | [homepage](https://github.com/jonschlinkert/union-value"Set an array of unique values as the property of an object. Supports setting deeply nested properties using using object-paths/dot notation.")
104
-
*[unset-value](https://www.npmjs.com/package/unset-value): Delete nested properties from an object using dot notation. | [homepage](https://github.com/jonschlinkert/unset-value"Delete nested properties from an object using dot notation.")
170
+
Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new).
105
171
106
-
### Contributing
172
+
</details>
107
173
108
-
Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new).
174
+
<details>
175
+
<summary><strong>Running Tests</strong></summary>
109
176
110
-
### Contributors
177
+
Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:
_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_
121
189
@@ -125,26 +193,42 @@ To generate the readme, run the following command:
Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:
198
+
### Related projects
131
199
132
-
```sh
133
-
$ npm install && npm test
134
-
```
200
+
You might also be interested in these projects:
201
+
202
+
*[assign-value](https://www.npmjs.com/package/assign-value): Assign a value or extend a deeply nested property of an object using object path… [more](https://github.com/jonschlinkert/assign-value) | [homepage](https://github.com/jonschlinkert/assign-value"Assign a value or extend a deeply nested property of an object using object path notation.")
203
+
*[get-value](https://www.npmjs.com/package/get-value): Use property paths like 'a.b.c' to get a nested value from an object. Even works… [more](https://github.com/jonschlinkert/get-value) | [homepage](https://github.com/jonschlinkert/get-value"Use property paths like 'a.b.c' to get a nested value from an object. Even works when keys have dots in them (no other dot-prop library can do this!).")
204
+
*[has-value](https://www.npmjs.com/package/has-value): Returns true if a value exists, false if empty. Works with deeply nested values using… [more](https://github.com/jonschlinkert/has-value) | [homepage](https://github.com/jonschlinkert/has-value"Returns true if a value exists, false if empty. Works with deeply nested values using object paths.")
205
+
*[merge-value](https://www.npmjs.com/package/merge-value): Similar to assign-value but deeply merges object values or nested values using object path/dot notation. | [homepage](https://github.com/jonschlinkert/merge-value"Similar to assign-value but deeply merges object values or nested values using object path/dot notation.")
206
+
*[omit-value](https://www.npmjs.com/package/omit-value): Omit properties from an object or deeply nested property of an object using object path… [more](https://github.com/jonschlinkert/omit-value) | [homepage](https://github.com/jonschlinkert/omit-value"Omit properties from an object or deeply nested property of an object using object path notation.")
207
+
*[set-value](https://www.npmjs.com/package/set-value): Create nested values and any intermediaries using dot notation (`'a.b.c'`) paths. | [homepage](https://github.com/jonschlinkert/set-value"Create nested values and any intermediaries using dot notation (`'a.b.c'`) paths.")
208
+
*[union-value](https://www.npmjs.com/package/union-value): Set an array of unique values as the property of an object. Supports setting deeply… [more](https://github.com/jonschlinkert/union-value) | [homepage](https://github.com/jonschlinkert/union-value"Set an array of unique values as the property of an object. Supports setting deeply nested properties using using object-paths/dot notation.")
209
+
*[unset-value](https://www.npmjs.com/package/unset-value): Delete nested properties from an object using dot notation. | [homepage](https://github.com/jonschlinkert/unset-value"Delete nested properties from an object using dot notation.")
0 commit comments