express-stormpath-config

The configuration parser / validator for express-stormpath.

Usage no npm install needed!

<script type="module">
  import expressStormpathConfig from 'https://cdn.skypack.dev/express-stormpath-config';
</script>

README

express-stormpath-config

The configuration parser / validator for express-stormpath.

NPM Version NPM Downloads Build Status Coverage Status

This library is responsible for parsing and validating all express-stormpath configuration data. It is an internal module used by express-stormpath, and is not meant for general consumption.

Installation

To install this library, just run:

$ npm install express-stormpath-config

Usage

This library is pretty simple.

Firstly, you'll need to initialize a new Config object using the library like so:

var Config = require('express-stormpath-config');

var config = new Config({
  application: {
    name: 'My Stormpath Application'
  }
});

Secondly, you need to call the Config.validate(callback) method to validate the configuration data. You can do this like so:

config.validate(function(err) {
  if (err) {
    console.log('Uh-oh, something is invalid:', err);
  } else {
    console.log('Everything looks good to go!');
  }
});

Resources

Below are some resources you might find useful!

Contributing

You can make your own contributions by forking this repository, making your changes in a feature branch, and then issuing a pull request back to this repository on the master branch.

Here's how you might do this if you wanted to contribute something:

$ git clone https://github.com/stormpath/express-stormpath-config.git
$ cd express-stormpath-config
$ git checkout -b some-feature
$ # make changes
$ git commit -m "All done!"
$ # submit a pull request

We regularly maintain this repository, and are quick to review pull requests and accept changes!

We <333 contributions!

Copyright

Copyright ©2015 Stormpath, Inc. and contributors.

This project is open-source via the Apache 2.0 License.