typescript-plugin-styled-componentsでSyntheticEvent.extend.withConfig is not a functionのエラーで動かない

typescript-plugin-styled-componentsでSyntheticEvent.extend.withConfig is not a functionのエラーで動かない

2020年7月26日
スポンサーリンク

TypeScript x React x Styled-Componentをやろうと思って typescript-plugin-styled-componentsをいれていたら

react-dom.development.js:1580 Uncaught TypeError: SyntheticEvent.extend.withConfig is not a function
    at eval (react-dom.development.js:1580)
    at eval (react-dom.development.js:4128)
    at Object../node_modules/react-dom/cjs/react-dom.development.js (bundle.js:127)
    at t (bundle.js:1)
    at eval (index.js:31)
    at Object../node_modules/react-dom/index.js (bundle.js:129)
    at t (bundle.js:1)
    at eval (main.tsx:10)
    at Module../src/frontend/main.tsx (bundle.js:155)
    at t (bundle.js:1)

のエラーがでた

package.jsonを修正してバージョンを1.0.0に落とすと動く

    "typescript-plugin-styled-components": "^1.4.4",
...
    "typescript-plugin-styled-components": "1.0.0",

Reopening #213 as I'm still experiencing this issue despite the suggestion p…
github.com