syncano-node icon indicating copy to clipboard operation
syncano-node copied to clipboard

.uniqe() feature for listing data

Open Idered opened this issue 8 years ago • 0 comments

For example: .uniqe('name') will take only first unique record (by 'name' field)

Hmm, maybe this should be part of collections feature?

let sockets = data.sockets.list().then(sockets => 
  sockets.unique('name').sortBy('name')
)

data.sockets.list().then(sockets => 
  sockets.filter(item => item.name === 'malgun').update({name: 'mailgun'})
)

https://github.com/ecrmnn/collect.js

Idered avatar Nov 09 '17 11:11 Idered