I have a demo here
It's a simple react app using typescript and styled components.
I have a slider that changes the height of the red box that.
The red box is a styled component and I pass the height as a prop.
This all worked but stopped working when I surround it all in another styled component to style the page.
The console has lots of warnings like
The component styled.div with the id of "sc-dlnjwi" has been created dynamically.
You may see this warning because you've called styled inside another component.
To resolve this only create new StyledComponents outside of any render method and function component.
Can anyone explain whats happening here an why the slider won't work when inside another styled component