|
22 | 22 | * [Live rebuild](#live-rebuild)
|
23 | 23 | * [Using Tailwind plugins](#using-tailwind-plugins)
|
24 | 24 | * [Using with PostCSS](#using-with-postcss)
|
25 |
| - * [Rails Engines support](#rails-engines-support) |
26 | 25 | * [Custom inputs or outputs](#custom-inputs-or-outputs)
|
| 26 | + * [Rails Engines support (Experimental)](#rails-engines-support-experimental) |
27 | 27 | - [Troubleshooting](#troubleshooting)
|
28 | 28 | * [The `watch` command is hanging](#the-watch-command-is-hanging)
|
29 | 29 | * [Lost keystrokes or hanging when using terminal-based debugging tools (e.g. IRB, Pry, `ruby/debug`...etc.) with the Puma plugin](#lost-keystrokes-or-hanging-when-using-terminal-based-debugging-tools-eg-irb-pry-rubydebugetc-with-the-puma-plugin)
|
@@ -384,16 +384,18 @@ export default {
|
384 | 384 |
|
385 | 385 | Then you can use yarn or npm to install the dependencies.
|
386 | 386 |
|
387 |
| -### Rails Engines support |
| 387 | +### Custom inputs or outputs |
388 | 388 |
|
389 |
| -If you have Rails Engines in your application that use Tailwind CSS and provide an `app/assets/tailwind/<engine_name>/engine.css` file, entry point files will be created for each of them in `app/assets/builds/tailwind/<engine_name>.css` so they can be included in your host application's Tailwind CSS by adding `@import "../builds/tailwind/<engine_name>"` to your `app/assets/tailwind/application.css` file. |
| 389 | +If you need to use a custom input or output file, you can run `bundle exec tailwindcss` to access the platform-specific executable, and give it your own build options. |
390 | 390 |
|
391 |
| -> [!IMPORTANT] |
392 |
| -> Only imported in `app/assets/tailwind/application.css` engine CSS files will be included in the build. By default, no engine CSS files are imported. This give you flexibility on which engine CSS files you want to include in your build. |
| 391 | +### Rails Engines support (Experimental) |
393 | 392 |
|
394 |
| -### Custom inputs or outputs |
| 393 | +_This feature is experimental and may change in the future. If you have feedback, please join the [discussion](https://github.com/rails/tailwindcss-rails/discussions/355)._ |
395 | 394 |
|
396 |
| -If you need to use a custom input or output file, you can run `bundle exec tailwindcss` to access the platform-specific executable, and give it your own build options. |
| 395 | +If you have Rails Engines in your application that use Tailwind CSS and provide an `app/assets/tailwind/<engine_name>/engine.css` file, entry point files will be created for each of them in `app/assets/builds/tailwind/<engine_name>.css` so they can be included in your host application's Tailwind CSS by adding `@import "../builds/tailwind/<engine_name>"` to your `app/assets/tailwind/application.css` file. |
| 396 | +
|
| 397 | +> [!IMPORTANT] |
| 398 | +> You must `@import` the engine CSS files in your `app/assets/tailwind/application.css` for the engine to be included in the build. By default, no engine CSS files are imported, and you must opt-in to using the file in your build. |
397 | 399 |
|
398 | 400 | ## Troubleshooting
|
399 | 401 |
|
|
0 commit comments