Great that you want to contribute! Nice to have you onboard. 🚀 To get started, follow this contributing guideline to set up the project and work with us!
The following tools and softwares are necessary to develop this application:
name | version | link |
---|---|---|
Node.js | ^18.x (recommended) | Node.js v18 |
yarn | ^1.22.x | yarn |
After installing the necessary tools, you can run the commands below to start developing.
- clone the repository by running
git clone https://github.com/IamSebastianDev/vay.js.git
in your terminal or shell to clone the repo into the current directory. - run
yarn
oryarn install
to install the dependencies. - run
yarn setup
. This will install the necessary husky scripts.
yarn preci
: Removes all files inside the node_modules folder. Is part of the repository setup.yarn ci
: Installs all dependencies without generating a lockfile and throws and error if an update is needed.yarn setup
: Installs husky and the hooksyarn build
: Builds the libraryyarn dev
: Build the library in watch modeyarn lint
: Runs alex as linteryarn test
: Runs AVA with the tests supplied in thetests
directoryyarn serve
: Serves the library into a minimal browser environment using byndly
This project uses multiple tools to enforce code quality:
The project uses conventional commits to ensure a certain commit message style.
feat
: Used when adding features to the application.fix
: Used when fixing a bug or issue.refactor
: Used when changing or improving code that is not a new feature or bug.chore
: Used when updating non application related code.
The project uses prettier to format the code to conform to a certain style. Formatting is enforced using pretty-quick as a pre-commit hook.
To develop a feature, checkout a new Branch from development
and prefix it with the correct branch type. The project currently differentiates between two branch types, feature
and bugfix
. For example, a branch to fix a bug would be created like this:
$ git checkout development
# checkout development as basis for development
$ git checkout -b bugfix/bug-to-fix
# creates a new branch with the correct branch type prefixed
If you add new functionality, tests should be added. The project uses AVA as test runner. Tests can be found under the tests
directory. Tests are written per file and should indicate which function they test. All tests are written in TypeScript.
- Publish: A automatic action that is triggered when merging into the
release
branch. Will create a new Release and publish it to npm.