ANN: Silk release

38 views
Skip to first unread message

Herby Vojčík

unread,
Mar 20, 2020, 8:47:27 AM3/20/20
to Amber ML
Hello!

There is new Silk release 0.5.2.

It brings better experience with namespaced structures.

Thanks Christian Haider for that. Citing from new code doc:

You can do:
svg := Silk newElement: 'svg' xmlns: 'http://www.w3.org/2000/svg'.
svg CIRCLE: {'cx' -> 60. 'cy' -> 25. 'r' -> 10}.
This creates a svg circle, not a html circle.

Also added is convenient message #newSvgElement, so above code can be:
svg := Silk newSvgElement. "aSilk newSvgElement works, too, & inserts"
svg CIRCLE: {'cx' -> 60. 'cy' -> 25. 'r' -> 10}.

Herby

Herby Vojčík

unread,
Mar 20, 2020, 9:44:10 AM3/20/20
to Amber ML
OK, an erratum: There were some additional changes needed, so there is
partly reverting release 0.5.3 (doesn't have #newSvgElement) as well as
new release 0.6.0 with fixes (needed new format of .js files compatible
only with amber >= 0.24; why, you ask; well, I extracted some common
functionality to a trait which used super send, that needs 0.24 to work).

In summary, I updated the `amber init` scaffolding, so after you update
it (hopefully npm -g install @ambers/cli could work), your `amber init`
creates new project with proper new Silk; or install new one in your
existing project via `npm install @ambers/silk@^0.6.0 --save`.

But, all in all, there is now Silk out there which allows easier svg (or
other namespaced hierarchies) creation.

Herby
Reply all
Reply to author
Forward
0 new messages