Skip to content
This repository was archived by the owner on Mar 22, 2019. It is now read-only.
This repository was archived by the owner on Mar 22, 2019. It is now read-only.

CSS custom properties value set as 0 (instead of 0px) #85

@Hiswe

Description

@Hiswe

Hello,

Thanks for your lib :)

I have some trouble though. This CSS

:root {
  --vh-offset: 0px;
}
html {
  height: 100vh;
  height: calc(100vh - var(--vh-offset));
}

will be transformed in something like this:

:root {
 /* no more units */
  --vh-offset: 0;
}
html {
  height: 100vh;
   /* will error */
  height: calc(100vh - var(--vh-offset));
}

which will break as pointed here

Is there an option for disabling the zero-value-unit transformation ?

Anyway I think I can hack it by setting my value to .00000000001px

[edit]

Yep this not-so-hack is working. Still I would prefer to be able to keep my units :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions