1.0.1 • Published 5 years ago

invoke-deep v1.0.1

Weekly downloads
1
License
MIT
Repository
github
Last release
5 years ago

invoke-deep

Recursively walks through an object and calls any function passing the object as parameter.

Installation

npm install invoke-deep

Usage

import invokeDeep from 'invoke-deep';

const result = invokeDeep({
  colors: ['red', 'green', 'blue'],
  font: {
    colors: config => config.colors,
  },
});

result.font.colors == ['red', 'green', 'blue'];