exclusive-properties

the properties that are in one of the objects but not the other

Usage no npm install needed!

<script type="module">
  import exclusiveProperties from 'https://cdn.skypack.dev/exclusive-properties';
</script>

README

install

npm install exclusive-properties

usage

var exclusive = require('exclusive-properties');
exclusive({a: 1, b: 2}, {b: 2, c: 3});
// => {a: 1, c: 3}

many arguments

Currently it only supports two arguments, but if you have an array of objects:

var res = objects.reduce(exclusive, {});