Why pluginVue must before pluginReact when both support Vue and React #4712
-
I need both support Vue and React in a project by multi-page but and I want to know the reason. |
Beta Was this translation helpful? Give feedback.
Answered by
chenjiahan
Mar 5, 2025
Replies: 2 comments
-
rsbuild.config.ts import { defineConfig } from '@rsbuild/core'
import { pluginReact } from '@rsbuild/plugin-react'
import { pluginVue } from '@rsbuild/plugin-vue'
export default defineConfig({
// plugins: [pluginReact(), pluginVue()], // error [VueLoaderPlugin Error] No matching use for vue-loader is found.
plugins: [pluginVue(), pluginReact()], // work
source: {
entry: {
react: './src/react.tsx',
vue3: './src/vue3.ts'
}
},
html: {
template({ entryName }) {
const templates = {
react: './static/react.html',
vue3: './static/vue3.html'
}
return templates[entryName] || './static/react.html'
}
}
})
|
Beta Was this translation helpful? Give feedback.
0 replies
-
This will be fixed by #4713 |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
baoanj
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This will be fixed by #4713