How to setup Material-UI for React with Typescript?

前端 未结 4 1210
夕颜
夕颜 2021-01-31 17:24

I\'ve run in some problems add Material UI to my React project, which is programmed with Typescript.

According to the tutorial, I start with adding the react-tab-event-p

4条回答
  •  栀梦
    栀梦 (楼主)
    2021-01-31 17:50

    Types are now bundled directly with Material-ui so there is no need to install @types/material-ui package.

    Instead you can just install the @material-ui/core package as normal and it should work.

    See the official Material-UI + Typescript example with create react app here: https://github.com/mui-org/material-ui/tree/master/examples/create-react-app-with-typescript

提交回复
热议问题