opened
nkint
username_0
Maybe I'm using it in the wrong way, but with his snippet I see an orange polyline, a red circle but I don't see a blue rect

```js
import { start } from "@thi.ng/hdom";
import { canvas } from "@thi.ng/hdom-canvas";

start(() => {
  return [
    canvas,
    { width: 100, height: 100 },
    [
      ["rect", { fill: "blue", stroke: "black" }, [20, 20], [10, 10]],
      [
        "polyline",
        { stroke: "orange" },
        [[0, 0], [0, 10], [10, 10], [10, 0], [0, 0]]
      ],
      ["circle", { fill: "red", stroke: "black" }, [100, 50], 25]
    ]
  ];
});

```
hdom canvas rect
issue
created
postspectacular
username_1
hey @username_0 - that's because the width and height should be given separately right now, but I just saw the readme still tells you otherwise, sorry! Will fix it. The size was originally a vector, but then updated to be more like the [rect args used by hiccup-svg](https://github.com/thi-ng/umbrella/blob/master/packages/hiccup-svg/src/rect.ts)... OTOH I think I'd prefer the size as vector, since that's also how it's stored in the [`Rect` class of the geom package](https://github.com/thi-ng/umbrella/blob/master/packages/geom/src/api.ts#L495) - so might change this back at some point.
comment
closed
nkint
username_0
issue
created
nkint
username_0
ok, thanks!
comment