bridgetown icon indicating copy to clipboard operation
bridgetown copied to clipboard

feat: make PostCSS optional…possibly off by default

Open jaredcwhite opened this issue 1 year ago • 3 comments

Two things have happened in the last year or two:

  • Vanilla CSS has gotten really, really good (shameless plug!).
  • esbuild has gotten better at transpiling certain CSS features for older browsers should you need that (like you can use nesting and have it flattened out). See: https://esbuild.github.io/content-types/#css

Because of this, and because I rarely reach for any particular PostCSS plugins in my own builds any more—in fact more and more my CSS is contained within declarative shadow DOM which I don't put through any processor—it's starting to feel like PostCSS is unnecessary complexity. Like Sass, it's a product of a bygone age.

So I find myself mulling over the idea of making PostCSS optional. And if that's a given, then the question becomes: do we truly make it an option? A "bundled configuration" perhaps? And not the default?

I'd love feedback from the community on this! If we go down this road, it makes the most sense to do it for Bridgetown 2.0. Otherwise I'd want to wait and revisit for Bridgetown 3.0.

jaredcwhite avatar Mar 07 '24 04:03 jaredcwhite

I find myself mulling over the idea of making PostCSS optional.

I'm always in favour of something that removes a build step.

do we truly make it an option?

I think we should still have it baked in so it could be set up with a flag passed into bridgetown new, but a default setup wouldn't have it included. I reckon that's the path we should take ....

ayushn21 avatar Mar 07 '24 10:03 ayushn21

I think as long as it is easy by default then off by default is not going to cause anyone any pain.

brandonzylstra avatar Mar 07 '24 20:03 brandonzylstra

@brandondrew @ayushn21 right, I'm definitely in favor of keeping it an easy option, but maybe we don't include it by default on every bridgetown new.

jaredcwhite avatar Mar 07 '24 21:03 jaredcwhite