-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hiccup and hiccup-seq? #35
Comments
Yep. That is what hiccup-seq is. A sequence (a list) of hiccup forms.
|
the reverse also works:
|
Just testing, hiccup does support this sequence:
Will update the documentation to make this clear |
As an additional note, reagent proclaims to use hiccup syntax but does not support the list form. In reagent: (defn test-page []
(list [:p "one"] [:p "two"]))
(defn current-page []
(fn []
[:div
[test-page]])) gives:
Trying a vector: (defn test-page []
(vector [:p "one"] [:p "two"]))
(defn current-page []
(fn []
[:div
[test-page]])) results in
defining a single hiccup form works: (defn test-page []
(last (list [:p "one"])) [:p "two"])
(defn current-page []
(fn []
[:div
[test-page]])) results in <div><p>two</p></div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In the readme, you mention hiccup can't represent sibling elements like:
But I'm pretty sure you can do this in Hiccup by wrapping it in a list like:
The text was updated successfully, but these errors were encountered: