Skip to content

Latest commit

History

History
197 lines (128 loc) 路 4.21 KB

CONTRIBUTING.md

File metadata and controls

197 lines (128 loc) 路 4.21 KB

Contributing

Table of Contents

Pull requests are welcome! By participating in this project, you agree to abide by our code of conduct.

Fork

Fork and then clone the repository:

# replace <USER> with your username
git clone git@github.com:<USER>/lilboards.git
cd lilboards

Install

Set the Node.js version with nvm:

nvm use

Install the dependencies:

npm install

Develop

Make your changes, add tests/documentation, and ensure tests and lint pass:

npm run test:ci
npm run lint:fix

Write a commit message that follows the Conventional Commits specification:

  • feat: A new feature
  • fix: A bug fix
  • perf: A code change that improves performance
  • refactor: A code change that neither fixes a bug nor adds a feature
  • test: Adding missing tests or correcting existing tests
  • build: Changes that affect the build system or external dependencies
  • ci: Changes to our CI configuration files and scripts
  • docs: Documentation only changes

The commit message will be linted during the pre-commit Git hook. To manually lint the most recent commit message:

git log -1 --pretty=format:"%s" | npx commitlint

Push to your fork and create a pull request.

At this point, wait for us to review your pull request. We'll try to review pull requests within 1-3 business days. We may suggest changes, improvements, and/or alternatives.

Things that will improve the chance that your pull request will be accepted:

  • Write tests that pass CI.
  • Write good documentation.
  • Write a good commit message.

Available Scripts

In the project directory, you can run:

npm start

Runs the app in the development mode.

Open http://localhost:5173 to view it in the browser.

The page will reload if you make edits.

You will also see any errors in the console.

npm run firebase:emulators

Starts the Firebase Emulators.

Open http://localhost:4000 to view it in the browser.

If you get the error:

Could not start Database Emulator, port taken.

Then run:

kill $(lsof -ti :9000) && npm run firebase:emulators

Or replace port 9000 with a different port (e.g., 9001) in .env and firebase.json.

npm test

Launches the test runner in the interactive watch mode:

npm test

Run tests with coverage:

npm run test:ci

View the coverage report in your browser:

open coverage/lcov-report/index.html

npm run build

Builds the app for production to the dist folder.

It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.

Your app is ready to be deployed!

npm run lint

Lints the codebase for ESLint errors:

npm run lint

Fix lint errors:

npm run lint:fix

Check types:

npm run lint:tsc

npm run cypress:open

Opens Cypress for E2E (end-to-end) testing.

If you get the error:

We attempted to make an http request to this URL but the request failed without a response.

We received this error at the network level:

  > Error: connect ECONNREFUSED 127.0.0.1:5173

Then expose the Vite server:

npx vite --host

Release

Release is automated with Release Please.