source: frontend/node_modules/underscore/modules/property.js

Last change on this file was 9af201e, checked in by MBK <marija.karapandzova@…>, 11 days ago

Fix frontend appearance

  • Property mode set to 100644
File size: 360 bytes
Line 
1import deepGet from './_deepGet.js';
2import toPath from './_toPath.js';
3
4// Creates a function that, when passed an object, will traverse that object’s
5// properties down the given `path`, specified as an array of keys or indices.
6export default function property(path) {
7 path = toPath(path);
8 return function(obj) {
9 return deepGet(obj, path);
10 };
11}
Note: See TracBrowser for help on using the repository browser.