Skip to content

godaddy/node-flipr-validation

Repository files navigation

node-flipr-validation

NPM

Build Status

This project is part of the flipr family.

node-flipr-validation provides validation for flipr config data and rules. You should use it to catch bad config changes before they are deployed. Bad config deployments make flipr very unhappy.

node-flipr-validation

#Usage

const fliprValidation = require('flipr-validation');
const errors = fliprValidation({
  config: myConfigObject,
  rules: myRulesArray
});

The errors array returned by fliprValidation will be empty if there are no validation errors. If there are validation errors, the errors array will contain one or more Error objects.

Flipr Validation Options

  • config - required - object: This is the config object you want to validate.
  • rules - optional - array: The array of rules you will use against this config. If you have rules but don't provide them, some of the validation will be skipped. It's a good idea to pass the rules if you have them.

Would you like to know more?

About

No description, website, or topics provided.

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Packages

No packages published