This is a little follow-up to my post about web components for date inputs.
If you try the demo on iOS it doesn’t work. There’s nothing stopping you selecting any date.
That’s nothing to do with the web components. It turns out that Safari on iOS doesn’t support min
and max
on date inputs. This is also true of any other browser on iOS because they’re all just Safari in a trenchcoat …for now.
I was surprised — input type="date"
has been around for a long time now. I mean, it’s not the end of the world. You’d have to do validation on inputted dates on the server anyway, but it sure would be nice for the user experience of filling in forms.
Alas, it doesn’t look like this is something on the interop radar.
What really surprised me was looking at Can I Use. That shows Safari on iOS as fully supporting date inputs.
Maybe it’s just semantic nitpickery on my part but I would consider that the lack of support for the min
and max
attributes means that date inputs are partially supported.
Can I Use gets its data from here. I guess I need to study the governance rules and try to figure out how to submit a pull request to update the currently incorrect information.
5 Shares
# Shared by Sebastian Laube on Tuesday, April 16th, 2024 at 8:47am
# Shared by Paul Kinlan on Tuesday, April 16th, 2024 at 9:14am
# Shared by Baldur Bjarnason on Tuesday, April 16th, 2024 at 9:40am
# Shared by crashposition on Tuesday, April 16th, 2024 at 10:43am
# Shared by Thomas Steiner :chrome: on Wednesday, April 17th, 2024 at 6:35am