1.0.10 • Published 6 years ago
misc-utils v1.0.10
misc-utils
This is a compilation of utility functions written in ES6 that I've been updating as and when I run into a requirement that isn't covered by something readily available off-the-shelf. A layer on top of lodash is what it looks like for the most part.
Install
npm install --save misc-utils
Usage
import { isVoid, deepDiff } from 'misc-utils'
...
let styleX = {
base: {
margin: '0 auto'
background: {
color: 'white'
}
}
}
let styleY = {
base: {
margin: 'auto'
},
active: {
width: '100%'
}
}
let styleDiff = deepDiff(styleX,styleY)
if (!isVoid(styleDiff)) {
console.log(styleDiff)
}
License
MIT © Thomas Varghese