1.0.1 • Published 2 years ago

grouparrayobject v1.0.1

Weekly downloads
-
License
ISC
Repository
-
Last release
2 years ago

This Package will group the Array of objects on the basis of key with comma seperated values.

const grouparrayobject = require('grouparrayobject')

let arrObject = { "name":"Rohan", "age":12}, { "name":"Mohit", "age":22}, { "name":"Shawn", "age":18}, { "name":"Michael", "age":19}, ;

console.log(grouparrayobject(arrObject));

will output-

{ name: 'Rohan,Mohit,Shawn,Michael', age: '12,22,18,19' }