defu
defu copied to clipboard
feat: add `defuSchema`
๐ Linked issue
Fixes #48
โ Type of change
- [X] ๐ Documentation (updates to the documentation, readme, or JSdoc annotations)
- [ ] ๐ Bug fix (a non-breaking change that fixes an issue)
- [ ] ๐ Enhancement (improving an existing functionality like performance)
- [X] โจ New feature (a non-breaking change that adds functionality)
- [ ] ๐งน Chore (updates to the build process or auxiliary tools and libraries)
- [ ] โ ๏ธ Breaking change (fix or feature that would cause existing functionality to change)
๐ Description
- Minor code improvement by using optional chaining as well when checking for merger function
- Create
defuSchemafor removing keys not present in the default object
๐ Checklist
- [X] I have linked an issue or discussion.
- [X] I have updated the documentation accordingly.
@pi0 Can I get a review in this please?
@pi0 Can I get a re-review of this please? Would be realy useful to have this upstream already ๐
Once last thing, it is missing in https://github.com/unjs/defu/blob/main/lib/defu.cjs
@pi0 Done!
@pi0 Hey sorry for pinging again about this... But it would be really useful to have this upstream!
@pi0 I fixed the conflicts after the merge of #121