Thank you for your interest in gatsby-plugin-component-to-image! This document outlines the guidelines for contributing to this project, including the development workflow and style guide.
By contributing to this project, you agree to release your contributions under the MIT License.
If you encounter any bugs or would like to request a new feature, please open an issue on GitHub.
Please include as much detail as possible, including the version of the project you are using, the steps to reproduce the issue, and any relevant error messages.
This project follows semantic versioning to better communicate the impact of changes to users.
Biome.js is used to enforce a consistent code style across the project. You can format the code by running pnpm biome format
or lint the code by running pnpm biome lint
, but the easiest way to ensure that your code is properly formatted is to install a Biome.js plugin for your code editor.
To contribute to this project, you will need to have the following tools installed on your machine:
After installing the prerequisites and cloning the repository, you can install the project dependencies by running pnpm install
.
This project is built using TypeScript. Running pnpm build
will compile source code in the src/
directory and output the compiled JavaScript files to the lib/
directory, along with type definitions.
When developing locally, keep in mind that the project will not automatically recompile when changes are made to the source code. You can run pnpm watch
to automatically recompile the project when you save changes to a file.
While developing, you can run pnpm test
to run the test suite. This will also generate a coverage report in the coverage/
directory.
Tests are run on the source .ts
files, so there is no need to build the project before running tests.
Please ensure that all tests pass and that the coverage does not decrease before opening a pull request.
If you need to clean the project directory, you can run pnpm clean
to remove the dist/
directory and any other generated files.
To create a new release:
- Update the version number in
package.json
according to the semantic versioning guidelines. - Run
pnpm pack
to create a tarball of the project. - Create a new release on GitHub and upload the tarball as an asset. This will trigger the publish workflow, which will automatically publish the package to npm.