Typescript Typings for fast-json-patch.
typings install --save fast-json-patch
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);
You can run them the tests with npm run build
and npm run test
.