Refactoring to Decouple HTML, CSS, and JS
After reading Tips for how to decouple your HTML, CSS, and JavaScript, I was struck by how stupid I’ve been marking up my HTML for CSS and JS events. I started rewriting my latest project using these principles and they’ve really helped create a separation of concerns. To illustrate how this has helped, I was coding up a quick administrative interface to CRUD some service model classes in my project and I started to really hate the UI/UX I chose. I decided to switch to a table since the data is more tabular in nature and I was quite please to see that none of the JavaScript functionality broke. ...