File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change 11
22export module ::
33
4+ map: method => [
5+ map & & &
6+ ]
7+
48kebab: method [content :string][
59 replace content "_" "-"
610]
@@ -22,8 +26,8 @@ voidElement: method [tag :string :literal :word htmlAttributes :dictionary][
2226 ;; <https://html.spec.whatwg.org/multipage/syntax.html#void-\elements/>
2327
2428 attributes: (
25- map htmlAttributes [key value] -> render {|\kebab key|="|value|"}
26- | append (map attrs [key value] -> render {|\kebab key|="|value|"})
29+ \ map htmlAttributes [key value] -> render {|\kebab key|="|value|"}
30+ | append (\ map attrs [key value] -> render {|\kebab key|="|value|"})
2731 | join.with: " "
2832 )
2933
@@ -51,7 +55,7 @@ element: method.public [tag :string :literal content :block :string :dictionary]
5155 if dictionary? content ->
5256 return \voidElement tag content
5357
54- attributes: (join.with: " " map attrs [key value] -> render {|\kebab key|="|value|"})
58+ attributes: (join.with: " " \ map attrs [key value] -> render {|\kebab key|="|value|"})
5559 if attributes <> "" -> prepend 'attributes " "
5660
5761 if block? content ->
You can’t perform that action at this time.
0 commit comments