const commonConfig = {
  presets: [["@babel/env", { loose: true }], "@babel/react"],
  plugins: ["dev-expression"]
};

module.exports = {
  babelrcRoots: [".", "packages/react-router-native/", "website/"],
  overrides: [
    {
      test: "./packages/react-router/modules/*",
      presets: commonConfig.presets,
      plugins: commonConfig.plugins.concat([
        ["@babel/proposal-class-properties", { loose: true }]
      ])
    },
    {
      test: "./packages/react-router-dom/modules/*",
      presets: commonConfig.presets,
      plugins: commonConfig.plugins.concat([
        ["@babel/proposal-class-properties", { loose: true }]
      ])
    },
    {
      test: "./packages/react-router-config/modules/*",
      presets: commonConfig.presets,
      plugins: commonConfig.plugins
    },
    {
      test: "./packages/website/modules/*",
      presets: commonConfig.presets,
      plugins: commonConfig.plugins.concat([
        "transform-class-properties",
        ["transform-object-rest-spread", { useBuiltIns: true }],
        "transform-export-default"
      ])
    }
  ]
};

@@ -787,294 +787,8 @@
 ins%0A
-    %7D,%0A    %7B%0A      test: %22./packages/website/modules/*%22,%0A      presets: commonConfig.presets,%0A      plugins: commonConfig.plugins.concat(%5B%0A        %22transform-class-properties%22,%0A        %5B%22transform-object-rest-spread%22, %7B useBuiltIns: true %7D%5D,%0A        %22transform-export-default%22%0A      %5D)%0A
     

remove website babel config from repo root config