Skip to main content Accessibility Feedback

Let buttons be buttons

From Matt Henry on Twitter:

Trying to book a flight, but the airline’s form has a span + javascript instead of a submit button. And it’s broken. Let buttons be buttons.

Reminder: progressive enhancement is not just about people who have JavaScript turned off (though it is about them, too). JavaScript is the most fragile part of your front-end stack, and when a file fails to load or you forget a semicolon or some other stupid bug emerges, you want people to still be able to use your site.

HTML first. Then CSS for style. Then JavaScript for enhancement functionality.


❄️ Black Friday Sale! Make 2018 the year you master JavaScript. From now through Monday, save up to 50% on my top JavaScript learning resources.

Have any questions or comments about this post? Email me at chris@gomakethings.com or contact me on Twitter at @ChrisFerdinandi.

Get Daily Developer Tips