Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 19 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,21 +72,37 @@ Voilà!

You should see the help output for the `tailwindcss` command. If you skipped step 2, the binary will be downloaded automatically on this first run. Use `tailwindcss` to create a new project or work with an existing *Tailwind CSS* project.

4. Create a new *Tailwind CSS* project by navigating to your project directory and initializing it:
4. For tailwind version below 4 and above 3, follow this step otherwise skip to 9th step - Create a new *Tailwind CSS* project by navigating to your project directory and initializing it:

```bash
tailwindcss init
```

This command creates the default *tailwind.config.js* file.

5. Start a watcher to compile CSS automatically during development:
6. For Tailwind version 4 and above create "tailwind.config.js" manually and add html file tracker details
```bash
export default {
content: [
"./app/**/*.html",
"./app/*.html",
"./app/**/*.js",
],
theme: {
extend: {},
},
plugins: [],
};
```

7. For Tailwind version 4 and above input.css file needs to import @import "tailwindcss"; only
8. Start a watcher to compile CSS automatically during development:

```bash
tailwindcss -i input.css -o output.css --watch
```

6. Compile and minify your CSS for production:
9. Compile and minify your CSS for production:

```bash
tailwindcss -i input.css -o output.css --minify
Expand Down