Open lzxb opened 2 weeks ago
我遇到过一个相似的问题,直接定义一个vue
别名解决了,不知道是不是你说的意思
// rsbuild.config.js
export default defineConfig({
// ..
source: {
alias: {
'@': resolve('src'),
'vue': resolve('node_modules/vue/dist/vue.runtime.esm-bundler.js'),
},
},
// ..
});
Thank you for your reply. You were referring to an alias, but I was referring to external expansion
What problem does this feature solve?
I am designing an ESM (ECMAScript Module) module linking with the intention of exporting multiple packages within a single file to reduce HTTP requests. When importing, aliases will be specified.
What does the proposed API of configuration look like?
Consolidate export files.
ssr-base/vue.ts
rspack.config.js