Skip to content

valimate.json

James Wright edited this page Mar 19, 2020 · 7 revisions

Valimate is configured on a per-project basis via the valimate.json config file. This must reside in the root directory of your project. A simple configuration might look like this:

{
  "urls": [
    "http://jamesswright.co.uk/",
    "http://jamesswright.co.uk/about-me",
    "http://jamesswright.co.uk/skills"
  ]
}

Options

Here are all the supported options. Default values are specified in (parentheses):

  • urls (undefined)

The URLs to be validated against the remote Nu Checker instance. Valimate will bork if this option isn't specified.

  • failHard (true)

If any of the URLs serve invalid markup, Valimate will exit with a status code of 1. This is desirable for continuous integration scenarios, as this will cause the current build to fail. By setting this property to false, Valimate will always exit with a successful status code, allowing builds to continue.

  • validatorUrl ('https://validator.w3.org/nu/')

The Nu validator instance to which Valimate sends markup

  • localAppServer (null)

One can test the HTML served by a local Node.js instance by setting the path to the entry point, as well as specifying any required environment variables. See the Running against a local app server wiki page for more details.