diff options
author | Marcin Chrzanowski <m@m-chrzan.xyz> | 2021-02-16 23:32:48 -0500 |
---|---|---|
committer | Marcin Chrzanowski <m@m-chrzan.xyz> | 2021-02-16 23:32:48 -0500 |
commit | 334fa6ba0b6b3d4ced4b963980febde56547bd12 (patch) | |
tree | bed488582c54e157805a44738874d104acc5b718 | |
parent | 5c1a10b93a5aa2d017e4bf259e4c3bb4ab3fc137 (diff) |
Add HTML reminders
-rw-r--r-- | html.md | 24 |
1 files changed, 24 insertions, 0 deletions
@@ -0,0 +1,24 @@ +# HTML stuff + +## DOM manipulation + + // create new element + document.createElement('button') + + // append child + element1.appendChild(element2) + +## Elements + +### Button + +By default, a button has type `reset` or `submit`, both of which reload the +page. To avoid reloading: + + <button type='button'></button> + +### Checkbox + +To check by default: + + <input type='checkbox' checked> |