JSPM

get-object

0.1.3
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 358605
  • Score
    100M100P100Q167936F

Get a object from a property on a nested object.

Package Exports

  • get-object

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (get-object) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

get-object NPM version

Get a object from a property on a nested object.

Usage

var get = require('get-object');

get({a: 'a', b: {c: 'd'}}, 'a')
//=> 'a'

get({a: 'a', b: {c: 'd'}}, 'b.c')
//=> 'd'

get({a: {b: 'c', c: {d: 'e', e: 'f', g: {h: 'i'}}}}, 'a.c.g.h')
//=> 'i'

Install

Install with npm:

npm i get-object --save-dev

Run tests

npm test

Run benchmarks

This implementation is between 50% and 250% faster than other implementations I tested.

node benchmark

Author

Jon Schlinkert

License

Copyright (c) 2014 Jon Schlinkert, contributors.
Released under the MIT license


This file was generated by verb-cli on October 08, 2014.