Commit 9db31d8
committed
chore: adapt babel config to v8
Remove deprecated `useSpread` option (always-on in Babel 8) and scope
`@babel/preset-react` to `.tsx` files only via overrides. Babel 8's
`@babel/preset-typescript` no longer passes `isTSX: false` for `.ts`
files, so preset-react's globally-added JSX transform would otherwise
make the parser treat TypeScript generic syntax like `<T = ...>` as
JSX and fail to compile.1 parent 8f3ed1a commit 9db31d8
1 file changed
Lines changed: 13 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | 10 | | |
18 | 11 | | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
19 | 25 | | |
20 | 26 | | |
21 | 27 | | |
| |||
0 commit comments