Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
whoisthemachine
on June 23, 2021
|
parent
|
context
|
favorite
| on:
HTML Data List Element
Yeah it's kind of awkward. My first assumption would have been that it would have had semantic similarities to a `<select>`, ie
<input type="datalist"> <option>a</option> </input>
chrismorgan
on June 23, 2021
|
next
[–]
<input> has been an empty element right from the start, meaning it mustn’t have any children. (And the HTML syntax enforces this.)
CodesInChaos
on June 23, 2021
|
prev
[–]
AFAIK <input> is hardcoded as self-closing in the html5 parser.
whoisthemachine
on June 23, 2021
|
parent
[–]
Hm interesting... presumably this could be changed though? We aren't locked to <input> following one convention, are we?
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: