mutt-json-patch
v0.0.1
Published
A extension to Mutt Forms to allow a JSON Patch diff to be generated from populated form data vs inputted data
Downloads
4
Maintainers
Readme
Mutt Forms Plugin - JSON Patch extension
A simple plugin to allow for JSON patch diff's to be generated from originally populated data vs user inputed data
Install:
yarn add mutt-forms-json-patch
Usage:
import Mutt from 'mutt-forms'
import MuttJsonPatch from 'mutt-forms-json-patch'
Mutt.use(MuttJsonPatch)
let form = Mutt({}, {})
form.populate({
name: 'Test'
})
// Some changes to the form...
let patch = form.getJSONPatch()