New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

json-diet

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

json-diet

Skeletonize your json

latest
Source
npmnpm
Version
0.1.9
Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

json-diet

Travis

skeletonize your json object

returns last elements type

use in node-js

npm install json-diet

usage

var diet=require("json-diet");

supports AMD

  require(["json-diet"],function(diet){
  });

wild web is support

  <script src="json-diet.js"></script>

USAGE

diet({
  "do": "doe a deer a female deer",
  "re": "a drop of golden sun",
  "me":{
    "name": "I call my self"
  },
  "fa": "a long long way to run",
  "so": {
    "needle": {
      "pulling": 0,
      "thread": "~"
    }
  },
  "la": "a note to follow sew",
  "ti": {
    "drink": {
      "with": ["jam", "bread"]
    }
  }
}).result();

USAGE RESULT

{
  do: 'string',
  re: 'string',
  me: { name: 'string' },
  fa: 'string',
  so: { needle: { pulling: 'number', thread: 'string' } },
  la: 'string',
  ti: { drink: { with: 'array' } }
}

LICENSE

MIT

Keywords

json

FAQs

Package last updated on 31 Mar 2017

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