The Pattern Library project is an open-source repository. As suhc, we follow to the most part the standard open-source Github contribution process. This document will walk you through the details.
We have adopted the Contributor Covenant's Code of Conduct and we expect you will adhere to it while making any contribution to the project. Please read the full text here.
The project follows the standard semantic versioning practice. Every meaningful change must be documented in Changelog.
We adhere to a linear branching model with the changes directly targeted for the main
branch through pull requests. So, submit your PR to merge onto the main
branch.
We strive to release every merged commit on the main
branch as an npm package. So, sqash your commits in your PR into a single commit with a meaningful message. In any case, to adhere to this Commit to Release
philosophy, we use the Sqaush and Merge
strategy while merging a PR.
After a PR has been merged, a project maintainer will create a release to publish the commit as an npm package release.
We use GitHub Issues for tracking bugs and enhancements. Before you file a bug, make sure that the bug does not already exist.
You can also use the issue to discuss a new design pattern that you are planning to contribute before putting effort on an implementation.
The project maintainers will monitor the project for PRs. They will review your PR and merge it, request a change to it, or close it with an explanation. Here are a few things to consider before creating a PR:
- Fork the repo and create your branch from
main
. - Run
npm i
in the repo root. - Add applicable tests for your changes.
- Run
npm test
. Make sure you are not reducing the code coverage due to your new changes. - If you are contributing new patterns, expose them appropriately though
index.ts
files where applicable. - Add relevant examples in the examples folder where applicable
- Add/update documentation in the docs folder and update links from README appropriately.
- Update the package version in package.json using semantic versioning.
- Update package-lock.json with the same package version that's in package.json. One way to achieve consisteny between
package.json
andpackage-lock.json
is by runningnpm i
after updatingpackage.json
. Another way is to use the npm version command.
- Update the CHANGELOG.md with an entry for the new package version.
Prettier - an automatic code formatter has been configured for the project. Run npm run lint:fix
after making changes to the code to adhere to the style guide.
By contributing to this project, you are accepting that your contributions will be licensed under its MIT License.