@adamwathan Does Tailwind 4.x still support require()? I see it in the package exports field, but get an error when attempting to require @tailwindcss/postcss.
Yea, that's an ESM config file (.mjs). In this case, I'm integrating Tailwind with other tools that don't support module syntax yet, so looking to use require().
The syntax of the postcss config file doesn't matter. It'll load ESM postcss plugins just fine if you use module.exports = { … } instead (and make sure the config file is named right). *however*, yes the postcss plugin still supports CJS:
Looks like it might be the explicit full path. If I provide just the package name, it suddenly works. Haven't seen that before (and I load *A LOT* of node packages in CodeKit, as you might imagine):
Jan 26, 2025 · 12:30 AM UTC






