18 lines
462 B
TypeScript
18 lines
462 B
TypeScript
import { defineConfig } from '@rsbuild/core';
|
|
import { pluginBabel } from '@rsbuild/plugin-babel';
|
|
import { pluginReact } from '@rsbuild/plugin-react';
|
|
|
|
// Docs: https://rsbuild.rs/config/
|
|
export default defineConfig({
|
|
plugins: [
|
|
pluginReact(),
|
|
pluginBabel({
|
|
include: /\.[jt]sx?$/,
|
|
exclude: [/[\\/]node_modules[\\/]/],
|
|
babelLoaderOptions(opts) {
|
|
opts.plugins?.unshift('babel-plugin-react-compiler');
|
|
},
|
|
}),
|
|
],
|
|
});
|