1.0.3 • Published 6 years ago

@kingjs/descriptor.nested.array.scorch v1.0.3

Weekly downloads
-
License
MIT
Repository
github
Last release
6 years ago

@kingjs/descriptor.nested.array.scorch

Clears an array tree of undefined values.

Usage

Scorch an array tree of values like this:

'use strict';

var values = [
  undefined,
  ['tiger'],
  [undefined]
]

scorch(values);

values;

result:

[ [ 'tiger'] [ ] ]

API

declare function scorch(
  tree: NestedDescriptor
): void

Interfaces

Parameters

  • tree: The array tree whose nodes will be purged of properties with undefined values.

Install

With npm installed, run

$ npm install @kingjs/descriptor.nested.array.freeze

License

MIT

Analytics