阅读(4477)
赞(0)
Vite HMR API build
2022-03-08 10:19:45 更新
类型校验:
async function build(
inlineConfig?: InlineConfig
): Promise<RollupOutput | RollupOutput[]>
使用示例:
const path = require('path')
const { build } = require('vite')
;(async () => {
await build({
root: path.resolve(__dirname, './project'),
base: '/foo/',
build: {
rollupOptions: {
// ...
}
}
})
})()