Skip to content

Commit 89012a8

Browse files
committed
chore: update
1 parent 3ec92ac commit 89012a8

File tree

6 files changed

+14
-14
lines changed

6 files changed

+14
-14
lines changed

packages/core/src/types/config.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -179,12 +179,12 @@ export type StyleRedirect = {
179179

180180
export type DtsRedirect = {
181181
/**
182-
* Whether to automatically redirect the import paths of Typescript declaration output files.
182+
* Whether to automatically redirect the import paths of TypeScript declaration output files.
183183
* @defaultValue `true`
184184
*/
185185
path?: boolean;
186186
/**
187-
* Whether to automatically redirect the file extension to import paths based on the Typescript declaration output files.
187+
* Whether to automatically redirect the file extension to import paths based on the TypeScript declaration output files.
188188
* @defaultValue `false`
189189
*/
190190
extension?: boolean;
@@ -197,7 +197,7 @@ export type Redirect = {
197197
style?: StyleRedirect;
198198
/** Controls the redirect of the import paths of output asset files. */
199199
asset?: boolean;
200-
/** Controls the redirect of the import paths of output Typescript declaration files. */
200+
/** Controls the redirect of the import paths of output TypeScript declaration files. */
201201
dts?: DtsRedirect;
202202
};
203203

packages/plugin-dts/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ const defaultRedirect = {
183183
};
184184
```
185185

186-
Controls the redirect of the import paths of output Typescript declaration files.
186+
Controls the redirect of the import paths of output TypeScript declaration files.
187187

188188
```js
189189
pluginDts({
@@ -199,7 +199,7 @@ pluginDts({
199199
- **Type:** `boolean`
200200
- **Default:** `true`
201201

202-
Whether to automatically redirect the import paths of Typescript declaration output files.
202+
Whether to automatically redirect the import paths of TypeScript declaration output files.
203203

204204
- When set to `true`, Rslib will redirect the import path in the DTS output file to the corresponding relative path based on the [compilerOptions.paths](https://typescriptlang.org/tsconfig#paths) configured in `tsconfig.json`.
205205

@@ -219,7 +219,7 @@ import { foo } from '../foo'; // expected output './dist/utils/index.d.ts'
219219
- **Type:** `boolean`
220220
- **Default:** `false`
221221

222-
Whether to automatically redirect the file extension to import paths based on the Typescript declaration output files.
222+
Whether to automatically redirect the file extension to import paths based on the TypeScript declaration output files.
223223

224224
- When set to `true`, the import paths in DTS files will be redirected to the corresponding JavaScript extension which can be resolved to corresponding DTS file. The extension of the DTS output file is related to the `dtsExtension` configuration.
225225

website/docs/en/config/lib/redirect.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -203,11 +203,11 @@ import url from './assets/logo.mjs'; // expected output
203203

204204
## redirect.dts
205205

206-
Controls the redirect of the import paths of output Typescript declaration files.
206+
Controls the redirect of the import paths of output TypeScript declaration files.
207207

208208
### redirect.dts.path
209209

210-
Whether to automatically redirect the import paths of Typescript declaration output files.
210+
Whether to automatically redirect the import paths of TypeScript declaration output files.
211211

212212
- **Type:** `boolean`
213213
- **Default:** `true`
@@ -230,7 +230,7 @@ import { foo } from '../foo'; // expected output './dist/utils/index.d.ts'
230230

231231
### redirect.dts.extension
232232

233-
Whether to automatically redirect the file extension to import paths based on the Typescript declaration output files.
233+
Whether to automatically redirect the file extension to import paths based on the TypeScript declaration output files.
234234

235235
- **Type:** `boolean`
236236
- **Default:** `false`

website/docs/en/guide/migration/modernjs-module.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ export default defineConfig({
8989

9090
## TypeScript declaration
9191

92-
If you use Typescript in your `Modern.js Module` and need to generate declaration files, add the following changes:
92+
If you use TypeScript in your `Modern.js Module` and need to generate declaration files, add the following changes:
9393

9494
```js title="rslib.config.ts"
9595
import { defineConfig } from '@rslib/core';
@@ -146,7 +146,7 @@ In addition, you have to install the `@rsbuild/plugin-sass` package as `devDepen
146146

147147
<PackageManagerTabs command="add @rsbuild/plugin-sass -D" />
148148

149-
If you run Typescript together with Sass, you might run into DTS generation errors. This can be resolved by adding a `env.d.ts` file in your `/src` directory.
149+
If you run TypeScript together with Sass, you might run into DTS generation errors. This can be resolved by adding a `env.d.ts` file in your `/src` directory.
150150

151151
```ts title="src/env.d.ts"
152152
declare module '*.scss' {

website/docs/zh/guide/basic/typescript.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# 使用 Typescript
1+
# 使用 TypeScript
22

33
Rslib 默认支持 TypeScript,你可以直接在项目中使用 `.ts``.tsx` 文件。
44

website/docs/zh/guide/migration/modernjs-module.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ export default defineConfig({
8989

9090
## TypeScript 类型定义
9191

92-
如果你在 `Modern.js Module` 中使用 Typescript 并需要生成类型定义文件,请添加以下更改:
92+
如果你在 `Modern.js Module` 中使用 TypeScript 并需要生成类型定义文件,请添加以下更改:
9393

9494
```js title="rslib.config.ts"
9595
import { defineConfig } from '@rslib/core';
@@ -146,7 +146,7 @@ export default defineConfig({
146146

147147
<PackageManagerTabs command="add @rsbuild/plugin-sass -D" />
148148

149-
如果你在运行 Typescript 和 Sass,你可能会遇到 DTS 生成错误。这可以通过在 `/src` 目录中添加一个 `env.d.ts` 文件来解决。
149+
如果你在运行 TypeScript 和 Sass,你可能会遇到 DTS 生成错误。这可以通过在 `/src` 目录中添加一个 `env.d.ts` 文件来解决。
150150

151151
```ts title="src/env.d.ts"
152152
declare module '*.scss' {

0 commit comments

Comments
 (0)