tailwindcss-gulp-starter Tailwind Templates

Tailwindcss Gulp Starter

This is a simple Gulp setup for using Tailwind CSS.

Tailwind CSS Gulp Starter Project

This is a simple Gulp setup for using Tailwind CSS that:

  1. Processes your CSS (Tailwind CSS),
  2. Minifies your CSS (cleancss),
  3. Removes unused classes (purgecss) and,
  4. Adds vendor prefixes to CSS rules using caniuse.com (autoprefixer)

To get started, clone the project and install the dependencies:

# using npm
npm i

# Using Yarn
yarn

To start watching your JS /tailwind.js and CSS src/styles.css files for changes and automatically rebuild your tailwind stylesheet src/css/styles.css, run:

npm run -s dev

And add this to the head of your HTML files.

<link rel="stylesheet" href="src/css/style.css">

To build a production bundle, run:

npm run -s prod

After that you will have a ready to deploy bundle at /dist so change the link in head of your HTML files from src/ to dist/ like so:

<link rel="stylesheet" href="dist/css/style.css">

Top categories

Loading Svelte Themes