3 ms·
I've checked out the <Modal /> component [1]. What's the reason to go through so many hoops instead of just using the HTML native <dialog> element [2]? [1] htt
by super256 4y ago
I've checked out the <Modal /> component [1]. What's the reason to go through so many hoops instead of just using the HTML native <dialog> element [2]?
[1] https://github.com/steven-tey/precedent/blob/main/components/shared/modal.tsx https://github.com/steven-tey/precedent/blob/main/components...
[2] https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dialog#examples https://developer.mozilla.org/en-US/docs/Web/HTML/Element/di...
- kylemh 4y agohttps://www.oidaisdes.org/native-dialog-element.en/ https://www.oidaisdes.org/native-dialog-element.en/ covers it pretty well. it's not accessible... yet!
- brundolf 4y agoThe native <dialog> does very little on its own in terms of functionality. It's mainly there for accessibility/semantic markup