question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Module not found: Can't resolve 'emotion' after upgrading to emotion 10.0

See original GitHub issue

Bug Report

Describe the bug After upgrading my project and components to use the newest version of emotion, i get the following error when i try to run docz

./src/App/UI/components/PanelTabs/PanelTabs.js Module not found: Can't resolve 'emotion' in '/Users/bringel/source/snowdrop-web/src/App/UI/components/PanelTabs'

That file doesn’t try to import anything from emotion. Its emotion imports look like this:

import { css, jsx } from '@emotion/core';
import styled from '@emotion/styled';

To Reproduce

Upgrade to emotion 10 Run docz:dev

In order to allow us to quickly reproduce you issue please include a link to a reproduction repository.

Expected behavior

A clear and concise description of what you expected to happen…

Environment

  • OS: OS X 10.14
  • Node/npm version: Node 11.1 npm 6.4.1 yarn 1.10.1
  • docz 0.13.7
  • @emotion/core 10.0.5

Additional context/Screenshots Add any other context about the problem here. If applicable, add screenshots to help explain.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:3
  • Comments:9

github_iconTop GitHub Comments

8reactions
Damian-101commented, Feb 1, 2021
3reactions
rangermeiercommented, Aug 13, 2019

I had the same error after upgrading from emotion 9 to emotion 10 (not using docz though). Turned out I forgot to also update babel-plugin-emotion. Upgrading this fixed the issue for me. Hope this helps others who stumble on this issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Module not found: Can't resolve '@emotion/react'
I had a similar issue and I resolved it by calling: npm install @emotion/react. or yarn add @emotion/react.
Read more >
Module not found: Can't resolve @emotion/react | bobbyhadz
To solve the error "Module not found: Error: Can't resolve '@emotion/react'", make sure to install the @emotion/react package by opening your terminal in ......
Read more >
@emotion/styled - npm
Start using @emotion/styled in your project by running `npm i @emotion/styled`. There are 6709 other projects in the npm registry using ...
Read more >
Install - Emotion
If you're not using React, you should use the @emotion/css package. yarn add @emotion/react. or if you prefer npm. npm install ...
Read more >
module not found: error: can't resolve '@mui/material/box'
To fix this error, you must install the package '@mui/material ' before using it. Open the terminal and run the following command to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found