Skip to content

Commit e8787d0

Browse files
authored
Merge pull request #91 from jasalt/patch-3
Improve sequential rendering example section
2 parents e3b4e8c + b514898 commit e8787d0

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

content/documentation/html-rendering.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,13 +67,16 @@ To conditionally render parts of the HTML, the `if` expression can be used.
6767
# Evaluates to "<div><p>a</p><p>c</p></div>"
6868
```
6969

70-
## List rendering
70+
## Rendering sequential data structures
7171

72-
Similar to conditional rendering, the `for` expression can be used to render lists.
72+
Similar to conditional rendering, the `for` expression can be used to render iterables such as vectors, lists and sets.
7373

7474
```phel
7575
(html [:ul (for [i :range [0 3]] [:li i])])
7676
# Evaluates to "<ul><li>0</li><li>1</li><li>2</li></ul>"
77+
78+
(html [:ul (for [i :in [3 4 5]] [:li i])])
79+
# Evaluates to "<ul><li>3</li><li>4</li><li>5</li></ul>"
7780
```
7881

7982
## Raw Html

0 commit comments

Comments
 (0)