1.0.0 • Published 10 years ago
o-invert v1.0.0
o-invert
Returns a copy of object with inverted keys and values of an object
Install
$ npm install --save o-invertThe object's all values must be unique
Example
var invert = require('o-invert');
console.log(invert({name: "Vikram", surname: "Jadhav"}));
// -> { Vikram: 'name', Jadhav: 'surname' }require('o-invert')(object)
Arguments:
object: An object that to be inverted
Returns: Returns a copy of object with inverted keys and values of an object
License
© 2016 Vikram Jadhav. MIT License
1.0.0
10 years ago