Skip to content

Latest commit

 

History

History
116 lines (76 loc) · 1.79 KB

CONTRIBUTING.md

File metadata and controls

116 lines (76 loc) · 1.79 KB

Modern.js Contributing Guide

Thanks for that you are interested in contributing to Modern.js.

Developing

To develop locally:

  1. Fork this repository to your own GitHub account and then clone it to your local.

  2. Create a new branch:

    git checkout -b MY_BRANCH_NAME
  3. Install pnpm:

    npm install -g pnpm
  4. Install the dependencies with:

    pnpm run setup
  5. Go into package which you want to contribute.

    cd ./packages/
  6. Start developing.

Building

You can build single package, with:

cd ./packages/*
pnpm run build

build all packages, with:

pnpm run prepare

If you need to clean all node_modules/* the project for any reason, with

pnpm run reset

Testing

You need write th new tests for new feature or modify exist tests for changes.

We wish you write unit tests at PACKAGE_DIR/tests. Test syntax is based on jest.

Run Testing

pnpm run test

Linting

To check the formatting of your code:

pnpm run lint

Publishing

We use Modern.js Monorepo Solution to manage version and changelog.

Repository maintainers can publish a new version of all packages to npm.

  1. Fetch newest code at branch main.

  2. Install

    pnpm run setup
  3. Prepare

    pnpm run prepare
  4. Add changeset

    pnpm run change
  5. Bump version

    pnpm run bump
  6. Commit version change. The format of commit message should be chore: va.b.c which is the main version of current release.

    git add .
    git commit -m "chore: va.b.c"