docs(README): add and improve contributing guide, local development guide (#860)

This commit is contained in:
Levi (Nguyễn Lương Huy)
2023-11-22 16:20:44 +07:00
committed by GitHub
parent d39e2de935
commit 10ec3d533e
2 changed files with 36 additions and 34 deletions

View File

@@ -71,6 +71,17 @@ Visit https://ui.nuxt.com to explore the documentation.
- [vueuse/vueuse](https://github.com/vueuse/vueuse) - [vueuse/vueuse](https://github.com/vueuse/vueuse)
- [egoist/tailwindcss-icons](https://github.com/egoist/tailwindcss-icons) - [egoist/tailwindcss-icons](https://github.com/egoist/tailwindcss-icons)
## Contributing
Thank you for considering contributing to Nuxt UI. Here are a few ways you can get involved:
- Reporting Bugs: If you come across any bugs or issues, please check out the reporting bugs guide to learn how to submit a bug report.
- Suggestions: Have any thoughts to enhance Nuxt UI? We'd love to hear them! Check out the [contribution guide](https://ui.nuxt.com/getting-started/contributing) to share your suggestions.
## Local Development
Follow the docs to [Set up your local development environment](https://ui.nuxt.com/getting-started/contributing#_2-local-development-setup) and contribute.
## License ## License
Licensed under the [MIT license](https://github.com/nuxt/ui/blob/dev/LICENSE.md). Licensed under the [MIT license](https://github.com/nuxt/ui/blob/dev/LICENSE.md).

View File

@@ -9,7 +9,7 @@ Nuxt UI thrives thanks to its fantastic community ❤️, which contributes by s
Before reporting a bug or reporting a feature, please make sure that you have read through our documentation and existing [issues](https://github.com/nuxt/ui/issues). Before reporting a bug or reporting a feature, please make sure that you have read through our documentation and existing [issues](https://github.com/nuxt/ui/issues).
## Submitting a Pull Request ## Submitting a Pull Request (PR)
### 1. Before You Start ### 1. Before You Start
@@ -27,22 +27,33 @@ To begin local development, follow these steps:
git clone https://github.com/nuxt/ui.git git clone https://github.com/nuxt/ui.git
``` ```
2. Install dependencies and prepare the project: 2. Enable [Corepack](https://github.com/nodejs/corepack):
```sh
corepack enable
```
3. Install dependencies:
```sh ```sh
pnpm install pnpm install
```
4. Generate type stubs:
```sh
pnpm run dev:prepare pnpm run dev:prepare
``` ```
3. To configure your local development environment, use the following commands: 5. Configure your local development environment:
- To work on the **documentation** in the `docs` folder, run: - To work on the **documentation** located in the `docs` folder, run:
```sh ```sh
pnpm run dev pnpm run dev
``` ```
- To test the components located in the `playground` folder within `app.vue`, run: - To test the components using **playground**, run:
```sh ```sh
pnpm run play pnpm run play
@@ -84,46 +95,26 @@ pnpm run typecheck
### 3. Commit Conventions ### 3. Commit Conventions
Use Conventional Commits for commit messages with the following format: We use [Conventional Commits](https://www.conventionalcommits.org/) for commit messages, which allows a changelog to be auto-generated based on the commits. Please read the [guide](https://www.conventionalcommits.org/en/v1.0.0/#summary) through if you aren't familiar with it already.
``` #### Note
<type>(optional scope): <description>
[optional body] - `fix` and `feat` are for actual code changes (that might affect logic). For typo or document changes, use `docs` or `chore` instead:
[optional footer(s)] ~~`fix: typo`~~ -> `docs: fix typo`
```
#### Types - If you are working on a specific component, ensure that you specify the main scope of your commit in brackets. e.g.
- `feat` : for new features.
- `fix` : for bug fixes.
- `refactor` : for code changes that are neither bug fixes nor new features.
- `perf` : for code refactoring that improves performance.
- `test` : for code related to automatic testing.
- `style` : for refactoring related to code style (not for CSS).
- `docs` : for changes related to documentation.
- `chore` : for anything else.
#### Scope
Where the change occurred (e.g., `Table`, `Alert`, `Accordion`, etc.).
#### Description
A summary of the changes made.
#### Examples
``` ```
feat(Alert): new component feat(Alert): new component
chore(Table): improve accessibility chore(Table): improve accessibility
docs: migrate to @nuxt/ui-pro
``` ```
### 4. Making the Pull Request ### 4. Making a Pull Request
- Follow the guide for creating a pull request and ensure your PR's title adheres to the Commit Convention. Mention any related issues in the PR description. - Follow along the [instructions](https://github.com/nuxt/ui/blob/main/.github/PULL_REQUEST_TEMPLATE.md?plain=1) provided when creating a PR
- Ensure your PR's title adheres to the [Conventional Commits](https://www.conventionalcommits.org/) since it will be used once the code is merged.
- Multiple commits are fine; no need to rebase or force push. We'll use `Squash and Merge` when merging. - Multiple commits are fine; no need to rebase or force push. We'll use `Squash and Merge` when merging.