Socket
Socket
Sign inDemoInstall

yam

Package Overview
Dependencies
5
Maintainers
3
Versions
26
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    yam

Dead simple storage interface


Version published
Maintainers
3
Install size
268 kB
Created

Readme

Source

yam

Build Status

Dead simple lazy storage interface, useful to store cli or project settings. The file being parsed is expected in valid JSON format that can include comments.

Yam Constructor
var Yam = require('yam');

//looks for a .test file in the current directory as well as your home directory
var yam = new Yam('test');

//customize where the file is located
var yam = new Yam('test', {
  primary: 'path/to/primary/location',
  secondary: 'path/to/secondary/location'
});

.test file example:

{
  //comments are valid
  'foo': 'bar'
}
Get
yam.get('foo'); // => 'bar'
GetAll
yam.getAll();

Keywords

FAQs

Last updated on 14 Jul 2018

Did you know?

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

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc