Closed
Description
Hi, I'm using "PostCSS Has Pseudo" in a Vue+Vite project to use :has() in lower versions of Firefox, such as 110.0.
I followed the opetaions in README.md:
npm install css-has-pseudo --save-dev
- Use it as a PostCSS plugin: import it and use it in the file "postcss.config.js"
- initialize cssHasPseudo: use it in the file "App.vue"
import cssHasPseudo from 'css-has-pseudo/browser'; cssHasPseudo(document);
It works when I run the project locally with a mock server, but it doesn't work when I build the project and run it with a real server. In the build product, there're ".js-has-pseudo [csstools-has-xxx" in the stylesheet, but there's no "[csstools-has-xxx" attribute added to the elements.
I think the operation "cssHasPseudo(document)" is the most important, but how can it works when building the project?