Skip to content

Releases: Palindrom/JSON-Patch-Queue

ES6 Module

06 Aug 11:32
Compare
Choose a tag to compare
ES6 Module Pre-release
Pre-release

Make target object per instance

16 Oct 10:53
Compare
Choose a tag to compare
Pre-release

Even though JSON-Patch-Queue always needed to be instantiated by its constructor, it used to act a bit like a collection of static methods, that's why it needed the target object obj to be passed to every receive and reset call (eg: receive(obj, patch)).

From 3.x, JSON-Patch-Queue is more like a class that you need to instantiate with all your details including the target object. And then operate with those passed details. This means you no longer need to pass the target object with every API call, calling receive(patch) and reset(newState) is sufficient.

CommonJS, ES6, and TS includes support

09 Mar 17:06
Compare
Choose a tag to compare

Now you can install JSON-Patch-Queue from NPM as in:

npm install json-patch-queue

Usage examples:

<script src='dist/json-patch-queue-synchronous.min.js'></script>

or

<script src='dist/json-patch-queue.min.js'></script>

in Node's CommonJS

var JSONPatchQueue = require('json-patch-queue').JSONPatchQueue;

Or

var JSONPatchQueue = require('json-patch-queue').JSONPatchQueueSynchronous;

in Node's TS and ES6

import { JSONPatchQueue } from 'json-patch-queue';

or

import { JSONPatchQueueSynchronous } from 'json-patch-queue';