Sorry, but you either have no stories or none are selected somehow.
If the problem persists, check the browser console, or the terminal you've run Storybook from.
If you use React Data Table across your application and you are customizing or using custom components often you'll find you are repeating alot of code.
The following pattern allows us to create a re-usable DataTable
with our defaults baked in. In this case, we want to ensure all our tables are dense
and have pagination
, and finally let's override React Data Tables components with some material-ui sexiness:
Now, instead of importing DataTable
you would import your custom DataTableBase
component and pass in your columns
, data
or whatever other React Data Tably property is needed:
We can do the same in TypeScript:
Usage: