Require Javascript Files Like A Rubyist
I like to keep my javascript files well-structured. I also like not to have to add a new <script> tag every time I add a new script file. It’s neater. In a Rails application, I use application.js to load all my other javascript files. Here’s how:
Observant readers will have noticed that I’m using jQuery with Rails here. You can do that now, you know.