sketch/size
Defines sizes directly with functions, to avoid conversions between int, float and strings.
Types
Size defines a CSS Unit. It can be either px, pt, vh, vw, em,
rem, lh, rlh, ch, %. To instanciate a Size, use the corresponding
functions. Every unit exposes two functions: the Int function (like px(0))
and the Float version suffixed by an underscore (like px_(0.0)).
pub opaque type Size
Functions
pub fn to_string(size: Size) -> String
Internal function, can be used if you need to go from a Size to a String in case you’re building on top of sketch.