You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I know this is probably a big ask here, but it would be great for this package to be infinitely customizable an work with more modern frameworks like tailwind.
As of now its really hard to update any of the styles
The text was updated successfully, but these errors were encountered:
Hello davidnoah
To make the package infinitely customizable and compatible with modern frameworks like Tailwind CSS, you could consider the following approach :
Move Styles to Configuration or Theme Files for exemple :
const defaultStyles = {
button: 'bg-blue-500 text-white px-4 py-2 rounded',
card: 'shadow-md border rounded-lg p-4',
};
export const getStyles = (customStyles) => ({
...defaultStyles,
...customStyles,
});
than Integrate Tailwind Compatibility
Instead of hardcoding styles, use utility classes from Tailwind CSS.
Provide a way for users to pass their own Tailwind classes.
Example:
);
};
3. Expose a Configuration API
Add an API that lets developers inject their own theme or Tailwind classes.
You can allow them to pass a configuration object at initialization.
for example:
import { configure } from 'your-package';
configure({
theme: {
button: 'bg-green-500 hover:bg-green-600 text-white font-bold',
},
});
4. Provide a Default Tailwind Theme
Offer a pre-built Tailwind configuration as the default theme.
This makes it easier for users already using Tailwind.
Example:
I know this is probably a big ask here, but it would be great for this package to be infinitely customizable an work with more modern frameworks like tailwind.
As of now its really hard to update any of the styles
The text was updated successfully, but these errors were encountered: