1.0.2 • Published 3 years ago

@firoxer/minimal-json-patch v1.0.2

Weekly downloads
6
License
MIT
Repository
github
Last release
3 years ago

minimal-json-patch

An implementation of RFC 6902 without bells or whistles.

Usage

import { applyPatch } from 'minimal-json-patch';

const originalDocument = {
  letters: ['a', 'b', 'd'],
};

const modifiedDocument = applyPatch(originalDocument, [
  { op: 'add', path: '/letters/2', value: 'c' },
]);

console.log(modifiedDocument.letters);
// [ 'a', 'b', 'c', 'd' ]

To-Do

  • Clearer error messages
  • More consistent error messages
1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago