Skip to content

typed-typings/npm-fast-json-patch

Repository files navigation

Typed fast-json-patch

Greenkeeper badge Build Status

Typescript Typings for fast-json-patch.

Installation

typings install --save fast-json-patch

Usage

import { apply } from 'fast-json-patch';

const obj = {
    foo: 1,
    baz: [{
        qux: 'hello'
    }]
};

const results = apply(obj, [{
    op: 'add',
    path: '/baz/0/foo',
    value: 'world'
}]);

console.log(results);

More examples

Contributing

You can run them the tests with npm run build and npm run test.