In a Rails 7 alpha2 with Tailwind (ie --css tailwindcss
), is it possible to create custom classes using @apply directives?
Currently, no.
Tailwind custom directives are not supported.
For that you would need to use some of the js bundler options, such as es-build
.
1 Like
You can do it now Release v2.0.0 · rails/tailwindcss-rails · GitHub. You have the full TW power with the new release
1 Like
Many thanks. Works perfectly!
1 Like