Skip to content

Commit bc48446

Browse files
committed
Update README
1 parent ec71230 commit bc48446

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,15 @@ button = html(t"<button id={element_id}>Click me</button>")
9797
# <button id="my-button">Click me</button>
9898
```
9999

100+
Multiple substitutions in a single attribute are supported too:
101+
102+
```python
103+
first = "Alice"
104+
last = "Smith"
105+
button = html(t'<button data-name="{first} {last}">Click me</button>')
106+
# <button data-name="Alice Smith">Click me</button>
107+
```
108+
100109
Boolean attributes are supported too. Just use a boolean value in the attribute
101110
position:
102111

0 commit comments

Comments
 (0)