Skip to content

Latest commit

 

History

History
107 lines (66 loc) · 3.94 KB

CONTRIBUTING.md

File metadata and controls

107 lines (66 loc) · 3.94 KB

Contributing to JSON-Logic

Table of Contents

What should I know before I get started?

Documentation

This project is documented with markdown for users in README.md and authors in CONTRIBUTING.md.

The API documentation is genrated by @adobe/jsonschema2md and can be found at ./docs#readme. Simply run npm run docs to create it.

A CHANGELOG.md is automatically generated based upon Conventional Commits.

A Table of Contents is automatically generated for both README.md and CONTRIBUTING.md by utilising doctoc.

You can also run npm run toc to manually trigger an update.

API

The whole API is specified with JSON Schema.

All schema files can be found in ./schemas and are validated by ajv - simply run npm run lint:schemas.

How to contribute code?

If you want/need to make changes to this package please open a Pull-Request.

Build

Simply run npm run build.

Development tools

Testing

Run npm test to execute unit tests.

All test fixtures are downloaded from:

This package is using qunit to write tests.

Styleguides

JavaScript

JavaScript is linted and autoformatted by a combination of prettier and eslint.

We extend Airbnb's JavaScript Styleguide available as eslint-config-airbnb-base.

Git Commit Messages

This project utilizes commitlint to enforce Conventional Commits.

These rules form the basis for our CHANGELOG.md and automatic versioning of releases.

Editors

Basic configuration for various editors is provided by an editorconfig file.

CI/CD

Git Hooks

We use husky and lintstaged to enforce those styleguide rules for each commit.

Travis

Travis CI is configured to lint source files, run all tests and run a build to check pull requests.

Releasing a new version

We stick to semantic versioning and use semantic-release to automatically generate a valid version, a CHANGELOG.md and to publish a new version to NPM here.

Simply run npm run release.