You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

fastpath

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fastpath

An optimised Jsonpath parser

2.1.0
latest
Source
npmnpm
Version published
Weekly downloads
15
-28.57%
Maintainers
1
Weekly downloads
 
Created
Source

fastPath Build Status

An attempt at an optimized jsonpath parser

Check the spec here: http://goessner.net/articles/JsonPath/

Use

var fastpath = require('fastpath');

var matcher = fastpath(pattern);

// or

var matcher = fastpath({
    name: pattern,
    name2: pattern2
});

matcher.evaluate(object);
PatternDescription
$the root object/element
@the current object/element
. or []child operator
..recursive descent
*wildcard - All objects/elements regardless of their names
[]Native array operator
[,]Names or array indices
[start : end : step]Slices subset of the array based on the start, end and step values
?()applies a filter

The tape tests have most of the patterns supported by the spec.

Keywords

jsonpath

FAQs

Package last updated on 10 May 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts