Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

dotprop

Package Overview
Dependencies
Maintainers
2
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dotprop - npm Package Compare versions

Comparing version 1.1.0 to 1.2.0

2

index.js

@@ -12,3 +12,3 @@ /**

if (propName == null || !holder) return holder;
var propParts = (propName + '').split('.');
var propParts = Array.isArray(propName) ? propName : (propName + '').split('.');
var result = holder, lastPropName;

@@ -15,0 +15,0 @@

{
"name": "dotprop",
"version": "1.1.0",
"version": "1.2.0",
"description": "Get property value by dot notation",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -12,4 +12,8 @@ # dotprop [![Build Status](https://travis-ci.org/dy/dotprop.svg?branch=master)](https://travis-ci.org/dy/dotprop)

getProp({}, 'a.b') // undefined
// recognizes arrays too
getProp({a: { b: { c: 1}} }, ['a', 'b', 'c']) // 1
getProp({a: { 'b.c': 1 }}, ['a', 'b.c']) // 1
```
[![NPM](https://nodei.co/npm/dotprop.png?downloads=true&downloadRank=true&stars=true)](https://nodei.co/npm/dotprop/)
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc