Skip to content

azer/get-json

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

get-json

Cross-platform library for getting JSON documents. Wraps request on Node, fallsback to JSONP on browsers.

$ npm install get-json

Usage

var getJSON = require('get-json')

getJSON('http://api.listenparadise.org', function(error, response){

    error
    // undefined

    response.result
    // ["Beth Orton — Stolen Car",
    // "Jack White — Temporary Ground",
    // "I Am Kloot — Loch",
    // "Portishead — Glory Box"]

    response.ok
    // => true

})

About

Get JSON docs on both Node and Browsers

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published