Skip to content

Commit 6d04832

Browse files
author
Ives van Hoorne
committed
Fix dependency transpiling for ts projects
1 parent 7ebff77 commit 6d04832

File tree

1 file changed

+5
-0
lines changed
  • src/sandbox/eval/presets/create-react-app-typescript

1 file changed

+5
-0
lines changed

src/sandbox/eval/presets/create-react-app-typescript/index.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import stylesTranspiler from '../../transpilers/css';
44
import typescriptTranspiler from '../../transpilers/typescript';
55
import jsonTranspiler from '../../transpilers/json';
66
import rawTranspiler from '../../transpilers/raw';
7+
import babelTranspiler from '../../transpilers/babel';
78

89
const preset = new Preset('create-react-app-typescript', [
910
'web.ts',
@@ -22,6 +23,10 @@ preset.registerTranspiler(module => /\.tsx?$/.test(module.path), [
2223
{ transpiler: typescriptTranspiler },
2324
]);
2425

26+
preset.registerTranspiler(module => /\.jsx?$/.test(module.path), [
27+
{ transpiler: babelTranspiler },
28+
]);
29+
2530
preset.registerTranspiler(module => /\.json$/.test(module.path), [
2631
{ transpiler: jsonTranspiler },
2732
]);

0 commit comments

Comments
 (0)