0.1.3 • Published 3 years ago

@zishone/dotnotate v0.1.3

Weekly downloads
138
License
MIT
Repository
github
Last release
3 years ago

dotnotate NPM Build codecov License

A utility function to convert JSON objects to dotnotation

Installation

$ npm i @zishone/dotnotate

Usage

1. Import dotnotate

const { dotnotate } = require('@zishone/dotnotate');

2. Dotnotate

const obj = { a: { b: { c: 1 } } };

const dotnotatedObj = dotnotate(obj);

console.log(JSON.stringify(dotnotatedObj, null, 2))
// {
//   'a.b.c': 1
// }

Authors

  • Zishran Garces

See also the list of contributors who participated in this project.

License

This project is licensed under the MIT License - see the LICENSE file for details.