Skip to content

Commit 16b1bd5

Browse files
authored
Enable decorators for TS CRA (codesandbox#2130)
1 parent e33124b commit 16b1bd5

File tree

1 file changed

+10
-1
lines changed
  • packages/app/src/sandbox/eval/presets/create-react-app

1 file changed

+10
-1
lines changed

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

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,16 @@ export default function initialize() {
104104
[
105105
{
106106
transpiler: babelTranspiler,
107-
options: babelOptions,
107+
options: {
108+
...babelOptions,
109+
config: {
110+
...babelOptions.config,
111+
plugins: [
112+
['proposal-decorators', { legacy: true }],
113+
...babelOptions.config.plugins,
114+
],
115+
},
116+
},
108117
},
109118
],
110119
true

0 commit comments

Comments
 (0)