v1.0.0-beta.46 fails to compile
See original GitHub issue- I have searched the issues of this repository and believe that this is not a duplicate.
Expected Behavior
To work.
Current Behavior
Failed to compile.
Steps to Reproduce (for bugs)
- Use create-react-app with typescript to create a new project
yarn global add create-react-app
create-react-app my-app --scripts-version=react-scripts-ts
cd my-app
- Install
v1.0.0-beta.46
yarn add material-ui@next
- Add any material-ui component to
src/App.tsx
...
import AppBar from 'material-ui/AppBar';
...
<AppBar position="static" />
- Do
yarn start
Error you get is
Failed to compile.
./node_modules/material-ui/styles/withStyles.js
Module not found: Can't resolve '@babel/runtime/core-js/map' in '/Users/talha/Repos/temp/my-app/node_modules/material-ui/styles'
Context
Your Environment
Tech | Version |
---|---|
Material-UI | ^1.0.0-beta.46 |
React | ^16.3.2 |
Issue Analytics
- State:
- Created 5 years ago
- Reactions:38
- Comments:11 (3 by maintainers)
Top Results From Across the Web
v1.0.0-beta.46 fails to compile · Issue #11285 · mui/material-ui
To work. Current Behavior. Failed to compile. Steps to Reproduce (for bugs). Use create-react-app with typescript to create a new project.
Read more >How can i resolve this error in React+Material UI
I have used the withStyles component, which is an higher order component of material ui.
Read more >Npm package installation error on other partition
I'm getting this error whenever I install a package from npm on ... npm ERR! command failed npm ERR! command sh -c node-gyp-build...
Read more >1.0.0-beta.46 - web3 - npm
Ethereum JavaScript API. Latest version: 1.8.1, last published: a month ago. Start using web3 in your project by running `npm i web3`.
Read more >web3.js-browser - UNPKG
11, * Download scripts in [build/](build) directory, or ; 12, * Use it as a typical [npm module](https://www.npmjs.com/package/web3.js-browser), or ; 13, * Import ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Try installing
@babel/runtime
or using v1.0.0-beta.45. I have forgotten about it 😕.As @oliviertassinari stated
npm install @babel/runtime
fixed the problem for me. PS: You don’t have to switch back to v1.0.0-beta.45.