Originally I had Tailwind purge enabled all the time but this can sometimes get in the way when doing rapid development locally. So this PR introduces distinct build tasks for local development (no purging) and production/CI (with purging). This works by toggling on and off a NODE_ENV flag that is used by Tailwind.
Going forward, use gulp build if you want a complete Tailwind CSS file and gulp build:dist for a much much smaller purged CSS file.
Remember to add specific paths to the following section of tailwind.config.js if you want them to be included in the purging process (e.g. the source files of a react app or a custom module that introduces additional templates).
Originally I had Tailwind purge enabled all the time but this can sometimes get in the way when doing rapid development locally. So this PR introduces distinct build tasks for local development (no purging) and production/CI (with purging). This works by toggling on and off a NODE_ENV flag that is used by Tailwind.
Going forward, use
gulp build
if you want a complete Tailwind CSS file andgulp build:dist
for a much much smaller purged CSS file.Remember to add specific paths to the following section of tailwind.config.js if you want them to be included in the purging process (e.g. the source files of a react app or a custom module that introduces additional templates).