Open jpt opened 4 years ago
I appreciate the mention of a workaround in the docs but I wonder if something like this would be a better pattern, similar to the behavior used by eslint (i.e. with a comment):
eslint
Input:
h1 { font-size: 48px; } h2 { /* pxtorem-disable-next-line */ font-size: 24px; }
Output:
h1 { font-size: 3rem; } h2 { font-size: 24px; }
I haven't looked at the source yet to see what kind of lift this would be, but would you accept a PR with this kind of solution?
Cheers, and thanks for the great library Jeremy
Yeah. Love the solution!
A similar solution could also be used for forcing the transformation of custom properties:
:root { /* pxtorem-transform */ --font-size-h1: 24px; }
I appreciate the mention of a workaround in the docs but I wonder if something like this would be a better pattern, similar to the behavior used by
eslint
(i.e. with a comment):Input:
Output:
I haven't looked at the source yet to see what kind of lift this would be, but would you accept a PR with this kind of solution?
Cheers, and thanks for the great library Jeremy