| marp | true |
|---|
It's about time...
- That ancient developer nemesis: timezones
- Q: Does anybody really know what time it is?
- A: the browser does
- User sees local time
- Server sees UTC
- (this bullet point intentionally left blank)
- datetime-utc-elements npm
- datetime-utc-output takes UTC and displays in browser local
- datetime-utc-input let user input in browser local but sends UTC to server
- datetime-local input
- hidden field for UTC
- keep em in sync
- worked like champ
Then I read this
- static property
formAsociated= true this.attachInterals()gives us anElementInternals
- updates the form's FormData
- uses the name attribute
- can take
- String
- File
- FormData
internals.setValidity()- validityState
- message (optional)
- internal input element (optional)