Prism · Sugar
$pluck
One field out of every record of a list. Shorthand for a $map whose body is a $get of that key.
{
users: [
{ id: 'u1', name: 'Ada' },
{ id: 'u2', name: 'Grace' },
{ id: 'u3', name: 'Linus' },
],
}{ $pluck: { over: { $ref: '$.users' }, key: 'name' } }['Ada', 'Grace', 'Linus']
Runs in this page on the installed package. The input and the expected output are defined by the example.