Is there any way to disable autoprefixer in development?
Hey there,
I've been using CRA for some time now and it really provides everything I need for the moment (it's mostly a React study project).
That said, is there a way to disable autoprefixer just for development env? I've seen some questions related to autoprefixer and PostCSS, but they said that ejecting was the way to go. I don't want to eject so if there's no way to do this without ejecting, I'll just forget about it.
Thank you
May I ask what the use case is?
But yes, if you edit your package.json:
"browserslist": {
"production": [
<existing entries>
],
"development": [
"last 1 chrome version",
"last 1 firefox version"
]
}
Setting development to "last 1" is basically telling autoprefixer to not prefix anything.
Hey there, thanks for the tip.
I want to do this because it annoys me to debug CSS on Chrome and see all the prefixed props. Not a big deal actually, just a little QoL improvement.
Did the tip above work for you?