logo
指南
配置
插件
API
English
简体中文
GitHub
Twitter
Discord
指南
配置
插件
API
English
简体中文
GitHub
Twitter
Discord
logo
Overview
plugins

dev

assetPrefix
beforeStartUrl
client
hmr
progressBar
setupMiddlewares
startUrl
writeToDisk

source

aliasStrategy
alias
define
entry
exclude
include
preEntry
transformImport

output

assetPrefix
charset
cleanDistPath
copy
cssModules
dataUriLimit
disableFilenameHash
disableMinimize
distPath
externals
filename
injectStyles
inlineScripts
inlineStyles
legalComments
overrideBrowserslist
polyfill
sourceMap
targets

html

appIcon
crossorigin
favicon
inject
meta
mountId
outputStructure
scriptLoading
tags
templateParameters
template
title

server

compress
headers
historyApiFallback
host
htmlFallback
https
port
proxy
publicDir
strictPort

tools

autoprefixer
bundlerChain
cssLoader
htmlPlugin
less
postcss
rspack
sass
styleLoader

performance

bundleAnalyze
chunkSplit
dnsPrefetch
preconnect
prefetch
preload
printFileSize
profile
removeConsole
removeMomentLocale

exclude#

  • 类型: RuleSetCondition[]
  • 默认值: []

指定不需要编译的 JavaScript/TypeScript 文件。用法与 Rspack 中的 Rule.exclude 一致,支持传入字符串或正则表达式来匹配模块的路径。

比如:

import path from 'path';

export default {
  source: {
    exclude: [path.resolve(__dirname, 'src/module-a'), /src\/module-b/],
  },
};
Edit this page on GitHub
上一页entry
下一页include
目录