Comments (1)
Hello,
No, setting to undefined directly would be best bet.
Other option is to get the value of the parent object, delete whatever property, and then set it back:
let item = dlv(obj, "items.0");
delete item.lastname;
dset(obj, "items.0", item);
Hope that helps
from dset.
Related Issues (20)
- Does this modify the objects? HOT 1
- Not really an issue. HOT 1
- Non-integers treated as valid indices for created arrays HOT 3
- Accept numbers as path elements HOT 2
- Create an inverse function HOT 3
- Immutable structures cannot be used unless a copy is created HOT 1
- Prototype pollution vulnerability HOT 1
- Break loop on magical key? HOT 2
- Trying to get in touch regarding a security issue HOT 2
- Strange bug using dset with mobx
- Question: why did you not choose the while loop? HOT 1
- Consider adding array merge strategy option HOT 1
- Merging objects at the root results in a no-op
- Prototype pollution vulnerability in merge function HOT 3
- `dset` creates array instead of object for nested empty string property
- `dset` throws when encountering `null` in object
- Returning the modified object would simplify immutability
- Vulnerability version 3.1.3 HOT 1
- Missing 3.1.4 GitHub Release
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dset.