Why JavaScript dialogs (alert/prompt/confirm) are not widely used and not under active development?
- by serg555
If there is a need to display some simple confirmation popup, most developers would rather install jQuery, find some dialog plugin for it, skin it, than put a one liner:
if(confirm("Are you sure?")) { ... }
Using alert() for displaying error messages is considered cheap.
And how many sites can you name that are usingprompt()?
So, the question is:
Is there something wrong with those dialogs so they should be avoided? Yes they have (very) limited functionality and customization, but when you don't need anything fancy, is using js dialogs still a bad practice?
Why these dialogs haven't seen any improvement in past 10 years (probably longer) and none is planned for near future? Wouldn't it be nice to have native js access to fully customizable desktop-level dialogs? At least adding error/warning/info type of dialogs and adding ability to customize button captions would be a big help.