2.1.4 • Published 4 years ago

@profiscience/knockout-contrib-utils-defaults v2.1.4

Weekly downloads
3
License
WTFPL
Repository
github
Last release
4 years ago

utils.defaults

Version Dependency Status Peer Dependency Status Dev Dependency Status Downloads

This package is intended for consumption via the @profiscience/knockout-contrib metapackage

Usage

defaults(dest, defaultValues, mapArrays = false)

Creates observables for enumerable properties of defaultValues where undefined in the destination object.

If mapArrayElements is true, array elements will be created using utils.fromJS.

import { defaults } from '@profiscience/knockout-contrib'

const foos = { foo: 'foo' }
defaults(foos, { foo: 'bar', bar: 'bar' })

foos()
// { foo: 'foo', bar: 'bar' }
2.1.4

4 years ago

2.1.2

4 years ago

2.1.3

4 years ago

2.1.0

5 years ago

2.0.1

5 years ago

2.0.0

5 years ago

2.0.0-rc.4

6 years ago

2.0.0-rc.3

6 years ago

2.0.0-rc.2

6 years ago

2.0.0-rc.1

6 years ago

2.0.0-rc.0

6 years ago

1.0.1

6 years ago

1.0.0-alpha.10

6 years ago

1.0.0-alpha.9

6 years ago

1.0.0-alpha.8

6 years ago

1.0.0-alpha.7

6 years ago

1.0.0-alpha.6

6 years ago

1.0.0-alpha.5

6 years ago

1.0.0-alpha.4

6 years ago

1.0.0-alpha.3

6 years ago

1.0.0-alpha.2

6 years ago

1.0.0-alpha.1

6 years ago

1.0.0-alpha.0

7 years ago