constant-mirror
A simple tool for creating objects with keys mirrored as values. Inspired by React's keyMirror.
Install
npm install --save constant-mirror
Usage
// ES6;// or ES5var mirror = ; ;// => { HELLO: 'HELLO', WORLD: 'WORLD' }
Symbol Mirror
// ES6;// or ES5var mirror = ; ;// => { HELLO: Symbol(HELLO), WORLD: Symbol(WORLD) }
License
MIT © Griffin Yourick