mirror of
https://github.com/status-im/reagent.git
synced 2025-01-13 13:24:47 +00:00
Add some examples of extended Hiccup to the README
This commit is contained in:
parent
3d6c2f5e3f
commit
91564be393
14
README.md
14
README.md
@ -41,6 +41,20 @@ Reagent uses [Hiccup-like](https://github.com/weavejester/hiccup) markup instead
|
||||
" text."]])
|
||||
```
|
||||
|
||||
Reagent extends standard Hiccup in one way: it is possible to "squeeze" elements together by using a `>` character.
|
||||
|
||||
```clj
|
||||
[:div
|
||||
[:p
|
||||
[:b "Nested Element"]]]
|
||||
```
|
||||
|
||||
can be written as:
|
||||
|
||||
```clj
|
||||
[:div>p>b "Nested Element"]
|
||||
```
|
||||
|
||||
You can use one component inside another:
|
||||
|
||||
```clj
|
||||
|
Loading…
x
Reference in New Issue
Block a user