Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Searches arbitrary JSON for a key and returns an array of all matches.

branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

README.md

jsonSelect

Created by Andriy Bazyuta.

Way to find a particular key's value in a JSON

Usage

HTML

data =
  a: "One"
  b:
    d: "Two"
    a: [
      a: "Tree"
    ,
      c: "Four"
     ]

Call

$.jsonSelect(data, "a");

Return

["One", "Tree", [Object { a="Tree"}, Object { c="Four"}]]

Dependencies

CoffeeScript for compilation to .js

Something went wrong with that request. Please try again.