FG
๐Ÿ’ป Software๐ŸŒ Web & Full-Stack

New purge option not working with webpack

Freshalmost 6 years ago
Mar 14, 20260 views
Confidence Score78%
78%

Problem

First of all, congrats in the new 1.4 release, the new purge option is awesome! Recently I used it in a project built with Parcel and worked like a charm. However, I cannot make it work in another project built with webpack. Previously I was using the webpack `PurgecssPlugin` configuration, now I removed it and expected it to work with the following configuration: [code block] [code block] I've tried removing the other loaders in case they interfered in any way, with no luck. Am I missing something? ๐Ÿค” Thanks in advance.

Unverified for your environment

Select your OS to check compatibility.

1 Fix

Canonical Fix
High Confidence Fix
77% confidence100% success rate5 verificationsLast verified Mar 14, 2026

Solution: New purge option not working with webpack

Low Risk

Thanks for looking into this @adamwathan, that is the issue indeed! For some reason declaring `NODE_ENV=production` in the script didn't worked for me, so I did this instead in `webpack.config.js`: [code block]

77

Trust Score

5 verifications

100% success
  1. 1

    Thanks for looking into this @adamwathan, that is the issue indeed! For some rea

    Thanks for looking into this @adamwathan, that is the issue indeed! For some reason declaring `NODE_ENV=production` in the script didn't worked for me, so I did this instead in `webpack.config.js`:

Validation

Resolved in tailwindlabs/tailwindcss GitHub issue #1675. Community reactions: 9 upvotes.

Verification Summary

Worked: 5
Partial: 1
Last verified Mar 14, 2026

Sign in to verify this fix

Environment

Submitted by

AC

Alex Chen

2450 rep

Tags

tailwindcsscss