New issue
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
"px" is removed from style attribute in template literal strings (lit-html) #1251
Comments
Hi @vmizgiris-equinix - what kind of CSS is it? |
@jakubpawlowicz, sorry - completely jumped my mind to mention this. This is lit-html template code, which in turn is JavaScript template literal strings. For example: import { html } from 'lit-html';
render() {
return html`<my-component style="--size: ${getSize()}px"></my-component>`;
} My code uses the minify-html-literals plugin under the hook which in turn uses clean-css. I've gotten around this issue by doing (Edited the issue title and description for clarity) |
Looks like there were a few other similar issues raised in the past, both using a similar syntax: |
@jakubpawlowicz, do you have any updates on this? |
px
is being removed from a style definition in template literal strings (lit-html).Environment
Configuration options
Input CSS
Actual output CSS
Expected output CSS
The text was updated successfully, but these errors were encountered: