We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug
When processing a file with @-webkit-keyframes rule content of that rule gets removed, except for to statement.
@-webkit-keyframes
to
To Reproduce Steps to reproduce the behavior:
@-webkit-keyframes shake-slow { 2% { -webkit-transform: translate(7px, 8px) rotate(3.5deg); transform: translate(7px, 8px) rotate(3.5deg); } 98% { -webkit-transform: translate(-4px, -6px) rotate(-2.5deg); transform: translate(-4px, -6px) rotate(-2.5deg); } 0%, to { -webkit-transform: translate(0) rotate(0); transform: translate(0) rotate(0); } } @keyframes shake-slow { 2% { -webkit-transform: translate(7px, 8px) rotate(3.5deg); transform: translate(7px, 8px) rotate(3.5deg); } 98% { -webkit-transform: translate(-4px, -6px) rotate(-2.5deg); transform: translate(-4px, -6px) rotate(-2.5deg); } 0%, to { -webkit-transform: translate(0) rotate(0); transform: translate(0) rotate(0); } }
purgecss --css file.css -con build/index.html --output file.css
@-webkit-keyframes shake-slow { to { -webkit-transform: translate(0) rotate(0); transform: translate(0) rotate(0); } } @keyframes shake-slow { 2% { -webkit-transform: translate(7px, 8px) rotate(3.5deg); transform: translate(7px, 8px) rotate(3.5deg); } 98% { -webkit-transform: translate(-4px, -6px) rotate(-2.5deg); transform: translate(-4px, -6px) rotate(-2.5deg); } 0%, to { -webkit-transform: translate(0) rotate(0); transform: translate(0) rotate(0); } }
Config file in current dir:
module.exports = { content: ["build/index.html", "build/static/js/*.js", "src/**/*.{ts,tsx}"], css: ["build/static/css/*.css"], output: "build/static/css", variables: true, fontFace: false, keyframes: false, safelist: { greedy: [/^components-/, /^firing-[0-9]$/, /^alert-history-loading-/], }, };
Expected behavior
Either @-webkit-keyframes should be remove entirely or not modified at all.
Screenshots
Environment (please complete the following information):
Additional context
The text was updated successfully, but these errors were encountered:
Just posting our working here for anyone interested:
const purgecss = new Purgecss({ content: [], // content css: [], // css safelist: [/\d{1,3}%/, 'from', 'to'] })
Sorry, something went wrong.
No branches or pull requests
Describe the bug
When processing a file with
@-webkit-keyframes
rule content of that rule gets removed, except forto
statement.To Reproduce
Steps to reproduce the behavior:
purgecss --css file.css -con build/index.html --output file.css
Config file in current dir:
Expected behavior
Either
@-webkit-keyframes
should be remove entirely or not modified at all.Screenshots
Environment (please complete the following information):
Additional context
The text was updated successfully, but these errors were encountered: