Created
November 15, 2018 09:27
-
-
Save Amli/c32a4e6bac59e61dd9fb67d5b18e710b to your computer and use it in GitHub Desktop.
JS Bin // source https://jsbin.com/lajebaz
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>JS Bin</title> | |
</head> | |
<body> | |
<ul> | |
<li>1</li> | |
<li>2</li> | |
<li>3</li> | |
<li>4</li> | |
<li>5</li> | |
<li>6</li> | |
<li>7</li> | |
<li>8</li> | |
<li>9</li> | |
<li>10</li> | |
</ul> | |
<script> | |
var list = document.getElementsByTagName('li'); | |
for (var i = 0; i < list.length; i++) { | |
list[i].remove(); | |
} | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment