array-functions

0.0.0 • Public • Published

array-functions NPM version NPM downloads Build Status

Read JS functions from JSON array.

Install

$ npm install --save array-functions

Usage

import test from 'ava'
import arrayFunctions from './'
 
test('main', t => {
    let json = [
        ['foo', 1, 2],
        ['bar', 1, 2]
    ]
 
    json = arrayFunctions(json)
 
    t.same(json, [
        {
            name: 'foo',
            args: [1, 2]
        },
        {
            name: 'bar',
            args: [1, 2]
        }
    ])
})

Related

License

MIT © EGOIST

Readme

Keywords

none

Package Sidebar

Install

npm i array-functions

Weekly Downloads

9

Version

0.0.0

License

MIT

Last publish

Collaborators

  • kchan