up
This commit is contained in:
parent
4272b7bb13
commit
508969c13f
168 changed files with 340 additions and 10 deletions
20
2-ui/1-document/07-modifying-document/4-clear-elem/task.md
Normal file
20
2-ui/1-document/07-modifying-document/4-clear-elem/task.md
Normal file
|
@ -0,0 +1,20 @@
|
|||
importance: 5
|
||||
|
||||
---
|
||||
|
||||
# clear
|
||||
|
||||
Create a function `clear(elem)` that removes everything from element.
|
||||
|
||||
```html run
|
||||
<ol id="elem">
|
||||
<li>Hello</li>
|
||||
<li>World</li>
|
||||
</ol>
|
||||
|
||||
<script>
|
||||
function clear(elem) { /* your code */ }
|
||||
|
||||
clear(elem); // clears the list
|
||||
</script>
|
||||
```
|
Loading…
Add table
Add a link
Reference in a new issue