Skip to content

Commit 090d7ba

Browse files
authored
docs: standardize heading case in documentation (#13051)
* docs: standardize heading case in documentation * docs: fix
1 parent d967d97 commit 090d7ba

File tree

16 files changed

+69
-69
lines changed

16 files changed

+69
-69
lines changed

AGENTS.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# Rspack
22

3-
## Project Overview
3+
## Project overview
44

55
Rspack is a high-performance JavaScript bundler written in Rust that offers strong compatibility with the webpack ecosystem.
66

7-
## Project Architecture
7+
## Project architecture
88

99
- **Monorepo** with Rust crates (`crates/`) and JavaScript packages (`packages/`)
1010
- See [Project Architecture](website/docs/en/contribute/development/project.md) for details
@@ -44,16 +44,16 @@ Depends on what you have modified, you need to rebuild by `pnpm run build:js` or
4444
- **JavaScript**: Use `--inspect` flag, attach with `Attach JavaScript`
4545
- **rust-lldb**: `rust-lldb -- node /path/to/rspack build` for panic debugging
4646

47-
## Code Quality
47+
## Code quality
4848

4949
- **Linting**: `pnpm run lint:js` (Biome), `pnpm run lint:rs` (cargo check), `pnpm run lint:type` (Rslint)
5050
- **Formatting**: `pnpm run format:rs` (cargo fmt), `pnpm run format:js` (prettier), `pnpm run format:toml` (taplo)
5151
- **Rust gate**: After modifying Rust code, ensure both `cargo fmt --all --check` and `cargo lint` pass before commit/PR
5252
- **Style**: snake_case for Rust, camelCase for JS/TS
5353

54-
## Common Tasks
54+
## Common tasks
5555

56-
### Adding a New Feature
56+
### Adding a new feature
5757

5858
1. Create feature branch from `main`
5959
2. Implement in appropriate crate/package
@@ -63,17 +63,17 @@ Depends on what you have modified, you need to rebuild by `pnpm run build:js` or
6363
6. Format: `pnpm run format:rs && pnpm run format:js`
6464
7. Create PR
6565

66-
### Modifying Code
66+
### Modifying code
6767

6868
- **Rust**: Core in `crates/rspack_core/`, plugins in `crates/rspack_plugin_*/`, rebuild with `pnpm run build:binding:dev`, test with `pnpm run test:rs`, and ensure `cargo fmt --all --check && cargo lint` passes
6969
- **JS/TS**: API in `packages/rspack/src/`, CLI in `packages/rspack-cli/src/`, rebuild with `pnpm run build:js`, test with `pnpm run test:unit`
7070

71-
### Adding Tests
71+
### Adding tests
7272

7373
- **Rust**: Add `#[test]` functions in same file or `tests/` directory
7474
- **JavaScript**: Add cases in `tests/rspack-test/{type}Cases/` (Normal, Config, Hot, Watch, StatsOutput, StatsAPI, Diagnostic, Hash, Compiler, Defaults, Error, Hook, TreeShaking, Builtin)
7575

76-
## Dependency Management
76+
## Dependency management
7777

7878
- **Package manager**: pnpm (workspaces for monorepo)
7979
- **Rust**: `Cargo.toml` in each crate
@@ -93,7 +93,7 @@ Depends on what you have modified, you need to rebuild by `pnpm run build:js` or
9393
- **API**: `website/docs/en/api/`
9494
- **Extract API**: `pnpm run api-extractor:local`
9595

96-
## Pull Request Guidelines
96+
## Pull request guidelines
9797

9898
- **Template**: Use `.github/PULL_REQUEST_TEMPLATE.md`
9999
- **Title prefix**: `test:`, `fix:`, `feat:`, `refactor:`, `chore:`
@@ -113,15 +113,15 @@ Depends on what you have modified, you need to rebuild by `pnpm run build:js` or
113113
- Prefer these types for release impact: `fix`, `feat`; use `!` or `BREAKING CHANGE:` only for incompatible changes
114114
- Keep PRs focused (one feature/fix per PR)
115115

116-
## Finding Code
116+
## Finding code
117117

118118
- **Rust core**: `crates/rspack_core/`
119119
- **Plugins**: `crates/rspack_plugin_*/`
120120
- **JavaScript API**: `packages/rspack/src/`
121121
- **CLI**: `packages/rspack-cli/src/`
122122
- **Tests**: `tests/rspack-test/`
123123

124-
## Error Handling
124+
## Error handling
125125

126126
- Use `rspack_error` crate for Rust errors
127127
- Provide clear, actionable error messages

crates/rspack_binding_api/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Shared binding API for Rspack, providing bridge interfaces between Rspack core f
1313
- `plugin`: Enable SWC plugin support
1414
- `sftrace-setup`: Enable performance tracing setup
1515

16-
## Important Notice
16+
## Important notice
1717

1818
⚠️ **Version Compatibility Warning**
1919

@@ -23,13 +23,13 @@ Shared binding API for Rspack, providing bridge interfaces between Rspack core f
2323
- It is recommended to lock specific version numbers in production environments
2424
- Please thoroughly test all functionality before upgrading
2525

26-
## API Usage Warning
26+
## API usage warning
2727

2828
🚨 **This package's API should NOT be used as a public Rust API**
2929

3030
This crate is designed to be linked as a **C dynamic library** during Rspack binding generation, not as a public Rust API for external consumption.
3131

32-
### For Developers
32+
### For developers
3333

3434
If you're working on Rspack itself:
3535

crates/rspack_tools/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ A toolkit for debugging and testing rspack internals.
44

55
## Commands
66

7-
### `compare` - Compare Cache In Directories
7+
### `compare` - Compare cache in directories
88

99
Compare the cache content of two directories to verify they contain identical data.
1010

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@
2626
"build:cli:release:browser": "pnpm --filter @rspack/binding build:release:browser && pnpm run build:js",
2727
"test:js": "pnpm -r run test",
2828
"format:rs": "cargo fmt --all",
29-
"format:js": "prettier . --write",
30-
"format-ci:js": "prettier . --check",
29+
"format:js": "prettier . --write && heading-case --write",
30+
"format-ci:js": "prettier . --check && heading-case",
3131
"format-ci:toml": "taplo format --check",
3232
"format:toml": "taplo format",
3333
"lint:js": "pnpm run lint-ci:js --write",
@@ -73,6 +73,7 @@
7373
"check-dependency-version-consistency": "^5.0.1",
7474
"commander": "14.0.3",
7575
"cross-env": "^10.1.0",
76+
"heading-case": "^1.0.7",
7677
"husky": "^9.1.7",
7778
"is-ci": "4.1.0",
7879
"lint-staged": "^16.2.7",

packages/rspack-test-tools/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
99
Test tools for rspack.
1010

11-
## Wasm Tests
11+
## Wasm tests
1212

1313
We expect to reuse the tests for Rspack wasm target as many as possible and we have managed to do it partially. Currently wasm tests should be run with an environment variable `WASM=1` under the following limitations:
1414

pnpm-lock.yaml

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/e2e/cases/lazy-compilation/cross-origin/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Cross-Origin Lazy Compilation Test
1+
# Cross-Origin lazy compilation test
22

33
This test verifies that lazy compilation works correctly
44
when the lazy compilation server runs on a different origin (port) than the frontend dev server.
@@ -38,7 +38,7 @@ when the lazy compilation server runs on a different origin (port) than the fron
3838
+----------------------+ | |
3939
```
4040

41-
## Key Points
41+
## Key points
4242

4343
1. **Two Separate Servers**: Frontend runs on port 8500, lazy compilation on port 8600
4444
2. **Cross-Origin Request**: Browser sends POST request to a different origin

website/docs/en/config/filename-placeholders.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ URL placeholders expose information about the current request URL.
115115
| -------- | ----------- |
116116
| `[url]` | URL value |
117117

118-
## Hash Length
118+
## Hash length
119119

120120
Hash placeholders (`[hash]`, `[contenthash]`, `[chunkhash]`) support length modifiers using `[hash:n]`, where the default length is 16.
121121

@@ -153,7 +153,7 @@ Entry chunks and chunks produced by [optimization.splitChunks](/plugins/webpack/
153153

154154
:::
155155

156-
## Escaping Placeholders
156+
## Escaping placeholders
157157

158158
If you want to preserve the literal placeholder text instead of having Rspack interpolate it, escape the brackets with backslashes.
159159

website/docs/en/config/module-rules.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import WebpackLicense from '@components/WebpackLicense';
44

55
<WebpackLicense from="https://webpack.docschina.org/configuration/module/" />
66

7-
# Module Rules
7+
# Module rules
88

99
- **Type:** `(Rule | Falsy)[]`
1010
- **Default:** `[]`

0 commit comments

Comments
 (0)