It’s been almost a year since we started using AngularJS in production here at Localytics. We began by experimenting with a small piece of our site and were so happy with it that we rewrote our entire analytics dashboard product — overhauling nearly four years’ worth of legacy production code — in Angular.
With a surprising lack of documentation or blog posts on real-world use of Angular on production Rails applications, we’ve had to be fairly creative with how we organized our code and integrated the two technologies. Most documentation on Angular code organization and workflow assumes a JavaScript/Grunt-centric worldview, and it was hard to see how we would introduce Grunt into our Rails kingdom, where Sprockets and Capistrano reign supreme. Meanwhile, we’ve seen a few cute examples on how to structure a fresh Angular/Rails hello-world seed app, but odds are, if you’re in production, you’ve already got a big steaming Rails app chugging away and don’t enjoy the luxury of starting from scratch with rails new my-todo-list-cookbook-twitter-seed-demo-world-app. So we thought we’d share some of the practices and tricks we’ve come up with at Localytics to get Angular running on Rails.
* Code Organization and the Asset Pipeline
* Testing
* Choosing the Right Tool
* Conclusion
Your new post is loading...