timjs/elm-collage/1.0.2

NOTE: this package is not compatible with Elm 0.19.1

Collage.Render

Technically, it should be possible to use different backends to render a collage, but we only provide a Svg backend here.

svg : Collage msg -> Html msg

Take a collage and render it to Html using Svg.

It uses the automatically calculated envelope from the Collage.Layout module as the view box.

svgBox : ( Float, Float ) -> Collage msg -> Html msg

Render a collage as Svg in a view box of given width and height, and the origin in the center.