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.

v2 broken with styled-components v3

See original GitHub issue

Expected Behavior

Version 2 should work with styled-components v3

Actual Behavior

My app does not compile with Grommet version 2 and styled-components v3. This error is thrown: Module build failed: Error: Cannot find module 'styled-components/lib/models/ThemeProvider'

URL, screen shot, or Codepen exhibiting the issue

One of the listed breaking changes for styled-components version 3:

Thanks to @Andarist we’re now shipping flat bundles for each of our entries only. This means that the entire lib/ folder won’t be inside our npm package. While this might break a couple of third party libraries, it stands to reason that our internals should not have been exposed in this way before.

More information here: https://www.styled-components.com/releases

Steps to Reproduce

  1. npm i grommet@next styled-components@3.0.2
  2. try to run app

Your Environment

  • Grommet version: grommet@next
  • Browser Name and version:
  • Operating System and version (desktop or mobile): Mac OS 10.13.2

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
srallencommented, Oct 11, 2018

It hasn’t been an issue for me with the latest releases.

0reactions
alansouzaticommented, Oct 11, 2018

we are on v4 now right ? is this still an issue?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Broken styles with 2 instances of styled-components on the ...
The problem is that I want to load 2 instances of styled-components on the same page. But when I do, the second overwrites...
Read more >
FAQs - styled-components
Note that for styled-components v3 and below, the previous API for global styles was injectGlobal. How can I override styles with higher specificity?...
Read more >
Styled-components is not working with react - Stack Overflow
I install styled components in my react project. but when I am styling using styled-components styling does not work.
Read more >
Upgrading to TDS V3 - TELUS Design System
TDS has now moved feature support from V2: Split Components to V3: Styled Components of the design system. This was done primarily to...
Read more >
styled-components | Yarn - Package Manager
3.2 - 2018-06-04 ... v3.3.1 was skipped due to a bad deploy. ... v2.2.4 - 2017-11-29. Disable static styles caching when hot module...
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