Skip to content

Commit

Permalink
docs: unify title capitalization style (#4350)
Browse files Browse the repository at this point in the history
  • Loading branch information
chenjiahan authored Jan 9, 2025
1 parent 35f6b82 commit 18b911c
Show file tree
Hide file tree
Showing 175 changed files with 615 additions and 611 deletions.
14 changes: 7 additions & 7 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Contributor Covenant Code of Conduct
# Contributor covenant code of conduct

## Our Pledge
## Our pledge

We as members, contributors, and leaders pledge to make participation in our
community a harassment-free experience for everyone, regardless of age, body
Expand All @@ -12,7 +12,7 @@ and orientation.
We pledge to act and interact in ways that contribute to an open, welcoming,
diverse, inclusive, and healthy community.

## Our Standards
## Our standards

Examples of behavior that contributes to a positive environment for our
community include:
Expand All @@ -36,7 +36,7 @@ Examples of unacceptable behavior include:
- Other conduct which could reasonably be considered inappropriate in a
professional setting

## Enforcement Responsibilities
## Enforcement responsibilities

Community leaders are responsible for clarifying and enforcing our standards of
acceptable behavior and will take appropriate and fair corrective action in
Expand Down Expand Up @@ -65,7 +65,7 @@ All complaints will be reviewed and investigated promptly and fairly.
All community leaders are obligated to respect the privacy and security of the
reporter of any incident.

## Enforcement Guidelines
## Enforcement guidelines

Community leaders will follow these Community Impact Guidelines in determining
the consequences for any action they deem in violation of this Code of Conduct:
Expand All @@ -91,7 +91,7 @@ includes avoiding interactions in community spaces as well as external channels
like social media. Violating these terms may lead to a temporary or
permanent ban.

### 3. Temporary Ban
### 3. Temporary ban

**Community Impact**: A serious violation of community standards, including
sustained inappropriate behavior.
Expand All @@ -102,7 +102,7 @@ private interaction with the people involved, including unsolicited interaction
with those enforcing the Code of Conduct, is allowed during this period.
Violating these terms may lead to a permanent ban.

### 4. Permanent Ban
### 4. Permanent ban

**Community Impact**: Demonstrating a pattern of violation of community
standards, including sustained inappropriate behavior, harassment of an
Expand Down
26 changes: 13 additions & 13 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# Rsbuild Contribution Guide
# Rsbuild contribution guide

Thank you for your interest in contributing to Rsbuild! Before you start your contribution, please take a moment to read the following guidelines.

---

## Setup the Environment
## Setup the environment

### Fork the Repo
### Fork the repo

[Fork](https://help.github.com/articles/fork-a-repo/) this repository to your
own GitHub account and then [clone](https://help.github.com/articles/cloning-a-repository/) it to your local.
Expand Down Expand Up @@ -39,7 +39,7 @@ nvm alias default 20
nvm use 20
```

### Install Dependencies
### Install dependencies

Enable [pnpm](https://pnpm.io/) with corepack:

Expand All @@ -59,7 +59,7 @@ What this will do:
- Create symlinks between packages in the monorepo
- Run the `prepare` script to build all packages, powered by [nx](https://nx.dev/).

### Set Git Email
### Set git email

Please make sure you have your email set up in `<https://github.com/settings/emails>`. This will be needed later when you want to submit a pull request.

Expand All @@ -83,19 +83,19 @@ git config user.email "SOME_EMAIL@example.com"

---

## Making Changes and Building
## Making changes and building

Once you have set up the local development environment in your forked repo, we can start development.

### Checkout A New Branch
### Checkout a new branch

It is recommended to develop on a new branch, as it will make things easier later when you submit a pull request:

```sh
git checkout -b MY_BRANCH_NAME
```

### Build the Package
### Build the package

Use [nx build](https://nx.dev/nx-api/nx/documents/run) to build the package you want to change:

Expand All @@ -113,13 +113,13 @@ pnpm run build

## Testing

### Add New Tests
### Add new tests

If you've fixed a bug or added code that should be tested, then add some tests.

You can add unit test cases in the `<PACKAGE_DIR>/tests` folder. The test runner is based on [Vitest](https://vitest.dev/).

### Run Unit Tests
### Run unit tests

Before submitting a pull request, it's important to make sure that the changes haven't introduced any regressions or bugs. You can run the unit tests for the project by executing the following command:

Expand All @@ -133,7 +133,7 @@ You can also run the unit tests of single package:
pnpm run ut packages/core
```

### Run E2E Tests
### Run E2E tests

Rsbuild uses [playwright](https://github.com/microsoft/playwright) to run end-to-end tests.

Expand Down Expand Up @@ -174,9 +174,9 @@ You can find the Rsbuild documentation in the [website](./website) folder.

---

## Submitting Changes
## Submitting changes

### Committing your Changes
### Committing your changes

Commit your changes to your forked repo, and [create a pull request](https://help.github.com/articles/creating-a-pull-request/).

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ The following diagram illustrates the relationship between Rsbuild and other too

![Rspack stack layers](https://assets.rspack.dev/rsbuild/assets/rspack-stack-layers.png)

## 📚 Getting Started
## 📚 Getting started

To get started with Rsbuild, see the [Quick Start](https://rsbuild.dev/guide/start/quick-start).

Expand Down Expand Up @@ -138,7 +138,7 @@ Please read the [Contributing Guide](https://github.com/web-infra-dev/rsbuild/bl
</table>
</a>

### Code of Conduct
### Code of conduct

This repo has adopted the ByteDance Open Source Code of Conduct. Please check [Code of Conduct](./CODE_OF_CONDUCT.md) for more details.

Expand Down
2 changes: 1 addition & 1 deletion README.pt-BR.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ Por favor leia o [Guia de Contribuição](https://github.com/web-infra-dev/rsbui
</table>
</a>

### Código de Conduta
### Código de conduta

Este repositório adotou o código de conduta de código aberto da ByteDance. Por favor, verifique [Código de Conduta](./CODE_OF_CONDUCT.md) para mais detalhes.

Expand Down
8 changes: 4 additions & 4 deletions e2e/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This folder contains the e2e test cases of Rsbuild.

## Tech Stack
## Tech stack

- [playwright](https://github.com/microsoft/playwright): The e2e test framework.

Expand All @@ -11,21 +11,21 @@ This folder contains the e2e test cases of Rsbuild.
Most of the E2E tests in Rsbuild are run by both Rspack and Webpack at the same time. This is to check that the functionality of Rspack is correctly aligned with Webpack.

```bash
# Run all test cases, including Rspack and Webpack
# Run all test cases, including Rspack and webpack
pnpm test

# Run test cases for Rspack
pnpm test:rspack

# Run test cases for Webpack
# Run test cases for webpack
pnpm test:webpack

# Run specific test case, such as "css"
pnpm test:webpack css
pnpm test:rspack css
```

## Add Test Cases
## Add test cases

Test cases added using the `test` method will run in both Rspack and Webpack.

Expand Down
6 changes: 3 additions & 3 deletions examples/README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# Rsbuild Examples
# Rsbuild examples

This folder contains some basic examples for Rsbuild, you can use these examples for debugging.

## More Cases
## More cases

More use cases can be found in [e2e/cases](../e2e/cases/).

## Add Examples
## Add examples

It is recommended to add more examples to [rspack-examples](https://github.com/rspack-contrib/rspack-examples).
2 changes: 1 addition & 1 deletion packages/compat/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Compat Packages
# Compat packages

The compat folder contains some packages that are used to test the compatibility of Rspack with webpack.

Expand Down
4 changes: 2 additions & 2 deletions packages/create-rsbuild/template-common/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Rsbuild Project
# Rsbuild project

## Setup

Expand All @@ -8,7 +8,7 @@ Install the dependencies:
pnpm install
```

## Get Started
## Get started

Start the dev server:

Expand Down
8 changes: 6 additions & 2 deletions website/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
# Rsbuild Website
# Rsbuild website

This website is built with [Rspress](https://github.com/web-infra-dev/rspress), the document content can be written using markdown or mdx syntax. You can refer to the [Rspress Website](https://rspress.dev/) for detailed usage.

## Contributing

Currently Rsbuild provides documentation in English and Chinese. If you can use Chinese, please update both documents at the same time. Otherwise, just update the English documentation.

### Image Assets
## Writing style guide

The same as Rspack: [Writing style guide](https://github.com/web-infra-dev/rspack/tree/main/website#writing-style-guide).

### Image assets

For images you use in the document, it's better to upload them to the [rspack-contrib/rstack-design-resources](https://github.com/rspack-contrib/rstack-design-resources) repository, so the size of the current repository doesn't get too big.

Expand Down
8 changes: 4 additions & 4 deletions website/docs/en/api/javascript-api/core.mdx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Rsbuild Core
# Rsbuild core

This section describes some of the core methods provided by Rsbuild.

Expand Down Expand Up @@ -212,7 +212,7 @@ The `mergeRsbuildConfig` function takes multiple configuration objects as parame
function mergeRsbuildConfig(...configs: RsbuildConfig[]): RsbuildConfig;
```

### Basic Example
### Basic example

```ts
import { mergeRsbuildConfig } from '@rsbuild/core';
Expand All @@ -235,7 +235,7 @@ console.log(mergedConfig); // { dev: { https: true } }

> This method will not modify the config object in the input parameter.
### Merge Rules
### Merge rules

In addition to deep merging, the `mergeRsbuildConfig` function also handles some options in a special way.

Expand Down Expand Up @@ -337,7 +337,7 @@ logger.debug('This is a debug message');
logger.log('This is a log message');
```

### Custom Logger
### Custom logger

You can use the `logger.override` method to override partial or all methods of the default logger:

Expand Down
4 changes: 2 additions & 2 deletions website/docs/en/api/javascript-api/environment-api.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

Here you can find all the environment related APIs.

> See [Multi-Environment Builds](/guide/advanced/environments) for more details.
> See [Multi-environment builds](/guide/advanced/environments) for more details.
## Environment Context
## Environment context

Environment context is a read-only object that provides some context information about the current environment.

Expand Down
12 changes: 6 additions & 6 deletions website/docs/en/api/javascript-api/instance.mdx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Rsbuild Instance
# Rsbuild instance

This section describes all the properties and methods on the Rsbuild instance object.

Expand Down Expand Up @@ -152,7 +152,7 @@ const result = await rsbuild.build({
await result.close();
```

### Stats Object
### Stats object

In non-watch mode, the `rsbuild.build() returns an Rspack [stats](https://rspack.dev/api/javascript-api/stats) object:

Expand All @@ -162,7 +162,7 @@ const result = await rsbuild.build();
console.log(result.stats);
```

### Custom Compiler
### Custom compiler

In some cases, you may want to use a custom compiler:

Expand Down Expand Up @@ -249,7 +249,7 @@ console.log(port); // 3000
await server.close();
```

### Custom Compiler
### Custom compiler

In some cases, you may want to use a custom compiler:

Expand All @@ -264,7 +264,7 @@ await rsbuild.startDevServer({
});
```

### Get Port Silently
### Get port silently

In some cases, the default startup port number is already occupied. In this situation, Rsbuild will automatically increment the port number until it finds an available one. This process will output a prompt log. If you do not want this log, you can set `getPortSilently` to `true`.

Expand Down Expand Up @@ -677,7 +677,7 @@ await rsbuild.inspectConfig({
});
```

### Output Path
### Output path

You can set the output path using `outputPath`. The default value is [output.distPath.root](/config/output/dist-path).

Expand Down
2 changes: 1 addition & 1 deletion website/docs/en/api/javascript-api/types.mdx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Rsbuild Types
# Rsbuild types

This section describes some of the type definitions provided by the Rsbuild.

Expand Down
Loading

0 comments on commit 18b911c

Please sign in to comment.