1.0.1 • Published 5 years ago

readsettings v1.0.1

Weekly downloads
4
License
MIT
Repository
github
Last release
5 years ago

ReadSettings Travis CI Build Status

Easily manage a configuration file for your application.

NPM Badge

Install

npm install readsettings

Usage

const ReadSettings = require("readsettings");

const config = new ReadSettings("myConfig.json");

config.data;
//=> {}

config.data.someKey = "Hello World!";

config.data;
//=> {somekey: "Hello World!"}

API

class ReadSettings(dir, options?)

dir

Type: string

The directory to store the settings file.

options

Type: Conf.Options<any>

Custom options to pass to conf.

instance ReadSettings extends Conf

data

Type: object

The currently stored data.