x/rambda/source/pluck.spec.js
123456789101112131415import {pluck} from './pluck'test('happy', () => { expect(pluck('a')([{a: 1}, {a: 2}, {b: 1}])).toEqual([1, 2])})test('with number', () => { const input = [ [1, 2], [3, 4], ] expect(pluck(0, input)).toEqual([1, 3])})