mirror of
https://github.com/facebook/react.git
synced 2026-02-27 03:07:57 +00:00
---
Currently on main, rollup does not inline source files
```js
// in packages/babel-plugin-react-forget
// $yarn build
// output
var CompilerError_1 = require("./CompilerError");
Object.defineProperty(exports, "CompilerError", { enumerable: true, get:
function () { return CompilerError_1.CompilerError; } });
// ...
```
I debugged a bit but not familiar with node or rollup.
- It seems that rollup fails to recognize source file imports with this setting,
as resolveId no longer gets called
- current `module` option defaults to `ESNext`, which works for some reason.
Let's revert for now to unblock syncs.
Sanity checked my repro by reinstalling node-modules and cleaning rollup cache.
31 lines
829 B
JSON
31 lines
829 B
JSON
{
|
|
"extends": "@tsconfig/node18-strictest/tsconfig.json",
|
|
"compilerOptions": {
|
|
"moduleResolution": "NodeNext",
|
|
"declaration": true,
|
|
"declarationDir": "./dist",
|
|
"declarationMap": false,
|
|
"rootDir": "src",
|
|
"outDir": "dist",
|
|
// https://github.com/microsoft/TypeScript/issues/30925
|
|
"tsBuildInfoFile": "dist/tsconfig.tsbuildinfo",
|
|
"jsx": "react-jsxdev",
|
|
// weaken strictness from preset
|
|
"importsNotUsedAsValues": "remove",
|
|
"noUncheckedIndexedAccess": false,
|
|
"noUnusedParameters": false,
|
|
"useUnknownInCatchVariables": true,
|
|
"target": "ES2015",
|
|
// ideally turn off only during dev, or on a per-file basis
|
|
"noUnusedLocals": false,
|
|
"composite": true,
|
|
},
|
|
"exclude": [
|
|
"node_modules",
|
|
"src/__tests__/fixtures"
|
|
],
|
|
"include": [
|
|
"src/**/*.ts"
|
|
]
|
|
}
|