The post addresses the challenge of computing `cos(25deg)` in CSS. Using a custom property directly fails, as the value is stored as a string. The solution involves using the `@property` rule to register the custom property with a number type, allowing the CSS engine to correctly compute and return the numeric value.

3m read timeFrom bram.us
Post cover image
Table of contents
The ProblemThe CauseThe SolutionAll together
2 Comments

Sort: