4.0.0 • Published 8 years ago

http2configuration v4.0.0

Weekly downloads
-
License
ISC
Repository
gitlab
Last release
8 years ago

http2configuration 🕵️‍

These are the schemas for http2server configuration files. They are shared between various related projects. This package acts as versioned truth, i.e. common ground.

ConfigurationValidator Class

Instance of the Validator class from jsonschema. Restricted to custom schemas and formats.

import {ConfigurationValidator} from 'http2configuration'

const validator = new ConfigurationValidator()
const configuration = { hosts: [ { domain: 'http2.live', root: 'public' } ] }

// Throws the first encountered error if the configuration syntax is invalid,
// otherwise returns `true`.
validator.validate(configuration)

JSON Schemas

options

The overall options schema defines the main structure of a configuration file.

import optionsSchema from 'http2configuration/schema/options'

host

The schema specifically for validating a host section of the configuration.

import hostSchema from 'http2configuration/schema/host'

manifest

Schema to validate the server push manifest configuration.

import hostSchema from 'http2configuration/schema/manifest'

See Also

4.0.0

8 years ago

3.2.0

8 years ago

3.1.0

8 years ago

3.0.0

8 years ago

2.0.0

8 years ago

1.0.0

8 years ago