Skip to content

Commit 2237565

Browse files
docs(en): merge docs-cn/sync-docs into docs-cn/dev @ a00ae88
2 parents 3bce02d + 0567eb0 commit 2237565

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

config/index.md

+9-1
Original file line numberDiff line numberDiff line change
@@ -311,14 +311,22 @@ export default defineConfig(async ({ command, mode }) => {
311311
- **类型:** `string | RegExp | (string | RegExp)[]`
312312
- **相关内容:** [静态资源处理](/guide/assets)
313313

314-
指定其他文件类型作为静态资源处理,因此:
314+
指定额外的 [picomatch 模式](https://github.com/micromatch/picomatch) 作为静态资源处理,因此:
315315

316316
- 当从 HTML 引用它们或直接通过 `fetch` 或 XHR 请求它们时,它们将被插件转换管道排除在外。
317317

318318
- 从 JavaScript 导入它们将返回解析后的 URL 字符串(如果你设置了 `enforce: 'pre'` 插件来处理不同的资产类型,这可能会被覆盖)。
319319

320320
内建支持的资源类型列表可以在 [这里](https://github.com/vitejs/vite/blob/main/packages/vite/src/node/constants.ts) 找到。
321321

322+
**示例:**
323+
324+
```js
325+
export default defineConfig({
326+
assetsInclude: ['**/*.gltf']
327+
})
328+
```
329+
322330
### logLevel {#loglevel}
323331

324332
- **类型:** `'info' | 'warn' | 'error' | 'silent'`

0 commit comments

Comments
 (0)