This repository demonstrates a bug in Tailwind CSS where the @apply
directive does not work correctly when used with custom directives added by plugins. The issue results in unexpected styling behavior or errors.
The @apply
directive, when used with directives defined within a Tailwind CSS plugin, fails to apply the styles as expected. This inconsistency affects the overall styling and may lead to unexpected visual results. The error message (if any) is not informative enough for easy debugging.
@apply
directive to apply the custom directive in your CSS.The provided solution addresses the issue by ensuring the proper configuration and usage of the @apply
directive with custom plugin directives. This is achieved by ensuring that the plugin is correctly imported and configured in the tailwind.config.js
file. Additionally, proper usage of the directive in the CSS file ensures successful style application.