Skip to content
This repository was archived by the owner on Sep 12, 2023. It is now read-only.

Add autoprefixer #8

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

karaggeorge
Copy link

@karaggeorge karaggeorge commented Oct 13, 2021

Since tailwind usually adds prefixes itself (https://tailwindcss.com/docs/browser-support#vendor-prefixes), I think this module might need to as well, otherwise some of the classes don't work properly.

I understand that this might increase the bundle size a lot, and even on the CLI it's an optional flag, so maybe it should create two separate bundles and document both, so if you want the autoprefixer and don't mind the extra size you can use it.

Or, it could be an extra option, and we load the autoprefixer dependency dynamically separately

It is sad that we load all of caniuse/browserlist when we know the exact browser this is running in, maybe there is a better solution?

Additionally adds logic to append the VIRTUAL_HTML_FILENAME key to the purge array, since if we load a user's config, their local file purge list will overwrite this and it won't actually apply any classes. Workaround for that is to modify the config before passing it to this module, but might be nice to handle the merge more gracefully

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant