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.

Third-party component seems broken after applying styled

See original GitHub issue

Used a couple of different third-party components and styling the parent element seems to break the third-party component functionality. Have checked all other questions etc… in the issues log and can’t see anything that would help to resolve this issue.

For example - import Collapse from ‘react-collapse’;

const Wrapper = styled.div ${wrapperStyles}

<Wrapper><h1>Some header</h1><Collapse>Some text...</Collapse></Wrapper>

Expected behaviour is smooth collapsing up and down but if using Wrapper you get a snapping behaviour, checking the code on both renders it looks like the style attribute is not getting appended as expected from the third-party component and if using a normal div without styling it does.

Love to hear from anyone who has experienced this same issue, any way to resolve this? Thanks!

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:1
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
mxstbrcommented, Dec 15, 2017

Closing due to inactivity, I’m assuming you’ve resolved your issue @puffstream! If not, please let me know and we’ll reopen this.

0reactions
jamesstar89commented, Dec 18, 2017

Sorted! Thank you 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Next.js: Broken styles when using styled-components #2042
Install via npx create-nx-workspace@latest sass --preset=next. Selecting SASS for styling image (note: styled-components unavailable here).
Read more >
Extending styles with styled-components not working
Extending, according to the docs, is when you have a styled component and you create a new one based on that. On the...
Read more >
FAQs - styled-components
Commonly asked questions about styled-components. ... In general, always use the css helper when composing styling partials to be interpolated into a styled...
Read more >
Solving the React Error: Not Picking Up CSS Style | Pluralsight
In this guide, you will learn about the errors that can occur while importing a CSS file into your React file.
Read more >
Styling in React: 5 ways to style React apps - LogRocket Blog
We will use a component that is part of a to-do application to explain these methods. While also considering the pros and cons...
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