Description
I've been spending way to many hours trying to get this plugin to work with our react, tailwind app. I was really excited about using it, but alas it is not going well. I've managed to put together a minimal reproducible Create React App (CRA) package here.
https://github.com/dreamboyx1/container-query-polyfill-example
- Mac Firefox 106.0.5 (64-bit)
- MacOS 12.6.1
Steps are:
npm install
npm run prod
This should start a static server using serve. You should then point your browser to: http://localhost:3000/
It will work ok running in development mode. That is, it will work as expected. It just does not work with a production build. So, I think some tailwind optimization or tree shaking is stomping on things. Not quite clear, yet. However, since this setup is super common, it would be great if this worked or at least there were some workaround to get it all working together.
I may dig in more, but I've more than exhausted my time box for now. Hopefully some other folks will be interested as well. Or maybe someone will tell me I'm an idiot and doing it wrong, which is ok and would not be the first time :).