Skip to content

Add support for a do-block syntax#34

Open
schneiderfelipe wants to merge 1 commit intoJuliaWeb:masterfrom
schneiderfelipe:do-block-syntax
Open

Add support for a do-block syntax#34
schneiderfelipe wants to merge 1 commit intoJuliaWeb:masterfrom
schneiderfelipe:do-block-syntax

Conversation

@schneiderfelipe
Copy link
Contributor

@schneiderfelipe schneiderfelipe commented May 20, 2021

This adds the proposed in/resolves #32:

julia> using Hyperscript

julia> @tags p

julia> p() do
           "child"
       end
<p>child</p>

julia> m("p") do
           "child"
       end
<p>child</p>

@MarkNahabedian
Copy link

Thanks for this. I prefer the do syntax to the argument syntax used by Hyperscript.

How would one add multiple children though?

@schneiderfelipe
Copy link
Contributor Author

Not sure. I have completely forgotten I coded this. 🤔 Feel free to use it for anything you like though. 🤗

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature request: do-block syntax

2 participants