File tree Expand file tree Collapse file tree 1 file changed +1
-15
lines changed
packages/vite/src/node/optimizer Expand file tree Collapse file tree 1 file changed +1
-15
lines changed Original file line number Diff line number Diff line change @@ -268,22 +268,8 @@ async function prepareRolldownScanner(
268
268
const { plugins : pluginsFromConfig = [ ] , ...rollupOptions } =
269
269
environment . config . optimizeDeps . rollupOptions ?? { }
270
270
271
- // TODO: enableDecorators when needed, wait for rolldown option
272
271
// The plugin pipeline automatically loads the closest tsconfig.json.
273
- // But esbuild doesn't support reading tsconfig.json if the plugin has resolved the path (https://github.com/evanw/esbuild/issues/2265).
274
- // Due to syntax incompatibilities between the experimental decorators in TypeScript and TC39 decorators,
275
- // we cannot simply set `"experimentalDecorators": true` or `false`. (https://github.com/vitejs/vite/pull/15206#discussion_r1417414715)
276
- // Therefore, we use the closest tsconfig.json from the root to make it work in most cases.
277
- // let tsconfigRaw = esbuildOptions.tsconfigRaw
278
- // if (!tsconfigRaw && !esbuildOptions.tsconfig) {
279
- // const { tsconfig } = await loadTsconfigJsonForFile(
280
- // path.join(environment.config.root, '_dummy.js'),
281
- // )
282
- // if (tsconfig.compilerOptions?.experimentalDecorators) {
283
- // tsconfigRaw = { compilerOptions: { experimentalDecorators: true } }
284
- // }
285
- // }
286
-
272
+ // Rolldown reads the tsconfig.json when a ts file is passed to it.
287
273
const plugins = await asyncFlatten ( arraify ( pluginsFromConfig ) )
288
274
289
275
plugins . push ( ...rolldownScanPlugin ( environment , deps , missing , entries ) )
You can’t perform that action at this time.
0 commit comments