preactjs/jest-preset-preact

What about use the automatic JSX transform

shinxi opened this issue · 0 comments

Not sure why we don't use the automatic JSX transform, so that don't need to add import {h, Fragment} from 'preact' at every component that needs JSX or Fragment.

From

[
'@babel/plugin-transform-react-jsx',
{
pragma: 'h',
pragmaFrag: 'Fragment',
},
],

to

[
  '@babel/plugin-transform-react-jsx', {
    "runtime": "automatic"
    },
]