can't figure out why adding import 'react-table/react-table.css' below import ReactTable from 'react-table'; doesn't add style on react-table and feels like no css is imported? I have to resort on importing CDN on index.html <link rel="stylesheet" href="https://unpkg.com/react-table@latest/react-table.css">, but my problem is, I cannot override css of the default classes? how can I override css of default classes and import react-table/react-table.css? why is it not working and affecting table?
What build environment are you using?
Your webpack/babel/etc configuration needs to know how to import .css files.
Also check your doctype is correct as this also impacts the styling....
https://github.com/react-tools/react-table/wiki/FAQ#my-reacttable-doesnt-seem-to-display-properly-on-browser-x---help
Since this is a question of implementation we invite you to continue the conversation in the react tools slack organization. Thanks! https://react-chat-signup.herokuapp.com/
Did you ever figure out how to get this to work? I've been struggling with the same thing and can't seem to figure out how to config webpack to get around the issue
If you are using webpack. it is likely you are excluding to parse 'node_modules' files. Since the style sheet is in
node_modules/react-table/react-table.css
You would need to change webpack config or just copy and paste the file into your style project folder.
src/styles/react-table.css
Is there any update on this? I'm running into the same issue and have been working tirelessly to resolve it to no avail.
I tried copying the .css file directly into my project, it didn't load maybe because it contains const??
@technificentConsulting Same issue 馃槥
@AleksandarAleksandrov I actually figured it out! https://stackoverflow.com/questions/51503415/react-table-css-not-loading-is-webpack-the-issue/51617858#51617858