I am using react-data-table component with server side pagination filtering and ordering, everything is working just fine, but I am getting these warning that I can't understand how to solve, I looked for a solution but I only found answers about declaring styled component outside the function, but the problem is it was not me who used styled component, it is react-data-table which is using it. Here is the warnings that I am getting:
Keyframes.js:20 The component styled.div with the id of "sc-bdnxRM" 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. Pe @
Keyframes.js:20 Keyframes.js:20 The component styled.div with the id of "sc-gtsrHT" 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. Pe
@ Keyframes.js:20 Keyframes.js:20 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. Pe
@ Keyframes.js:20 Keyframes.js:20 The component styled.div with the id of "sc-hKFxyN" 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. Pe @ Keyframes.js:20 Keyframes.js:20 The component Styled(styled.div) with the id of "sc-eCApnc" 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.
I am new to react and react-data-table.
I solved my problem by adding import "react-data-table-component"; in App.js , before this i had only called datatable from "react-data-table-component" in the component i created , it seems i had to import it in app.js as well