Skip to content

imthejano/get_object_in_object.npm.ts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Get object in object

Given a path divided by dots (example: 'foo.bar') you can find an object inside another parent object

Installation

npm install @imjano/get_object_in_object

Usage

const path = 'foo.bar'
const obj = { foo: { bar: 'hello' } }
console.log(getObjectInObject(obj, path)) //output: 'hello'

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published