Closed huangtiandi1999 closed 3 days ago
Do you mean this error?
This is a tip from the Vue compiler and has nothing to do with Rsbuild.
In version 3.2 and below, the generic type parameter for defineProps() were limited to a type literal or a reference to a local interface.
https://vuejs.org/guide/typescript/composition-api#syntax-limitations
In version 3.2 and below, the generic type parameter for defineProps() were limited to a type literal or a reference to a local interface.
https://vuejs.org/guide/typescript/composition-api#syntax-limitations
Thanks for your reply. Now I use Vue Marco library to support that imported from an external source, However, it should be noted that the @vue-macros/better-define version needs to be lower than v1.7.1, which may help guys with the same problem
import { defineConfig } from '@rsbuild/core';
import { pluginVue2 } from '@rsbuild/plugin-vue2';
import betterDefine from '@vue-macros/better-define/webpack';
export default defineConfig({
plugins: [pluginVue2()],
tools: {
rspack: (config) => {
config.plugins?.push(betterDefine());
return config;
},
},
});
Version
Details
fail to build
success to build
rsbuild.config.ts
package.json
Reproduce link
none
Reproduce Steps
none