Skip to content

Commit 0e64de7

Browse files
committed
CSS.px creates a CSSNumericValue
1 parent e07b92c commit 0e64de7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

css-typed-om/Overview.bs

+2-2
Original file line numberDiff line numberDiff line change
@@ -2763,10 +2763,10 @@ The way that a {{CSSStyleValue}} serializes is dependent on how the value was co
27632763
For example:
27642764

27652765
<pre class='lang-javascript'>
2766-
var length1 = CSSNumericValue.from("42.0px");
2766+
var length1 = CSSNumericValue.parse("42.0px");
27672767
length1.toString(); // "42.0px"
27682768

2769-
var length2 = CSSNumericValue.from(42.0, "px");
2769+
var length2 = CSS.px(42);
27702770
length2.toString(); // "42px";
27712771

27722772
element.style.width = "42.0px";

0 commit comments

Comments
 (0)