5.0.0 • Published 7 years ago

indices-for-same-value v5.0.0

Weekly downloads
1
License
MIT
Repository
github
Last release
7 years ago

Indices for same value

Get all the indices for a given value in an array.

    npm i -S indices-for-same-value
    const getAllIndices = require('indices-for-same-value').getAllIndices

    getAllIndices(10, [10, 2, 3, 4, 5, 6, 7, 10, 10 ,10])
    // returns
    // ["0", "7", "8", "9"]

Testing

jasmine

License

MIT © Git Faf 2017