Fix define-element code in README

This commit is contained in:
Jon Atack 2018-07-21 23:55:55 +02:00
parent a92da582c2
commit f54e36828a
No known key found for this signature in database
GPG key ID: A247476604717FE6

View file

@ -54,9 +54,9 @@ All children will be flattened as if they're given inline.
(div :id id :class "big-dog" (div :id id :class "big-dog"
children children
"dog") "dog")
((div :id id :class "small-dog" (div :id id :class "small-dog"
children children
"dog")))) "dog")))
``` ```
`dog` will be defined as a function that takes `:id` and `:size` keyword arguments. `dog` returns an user-defined element object. Inside it, `children` will be replaced with the children elements you provided when creating this `dog`: `dog` will be defined as a function that takes `:id` and `:size` keyword arguments. `dog` returns an user-defined element object. Inside it, `children` will be replaced with the children elements you provided when creating this `dog`:
``` ```