I'm using Restangular with Rails 4, and I wish to tell rails to skip precompiling Restangular as I'm using the official minified version which doesn't mangle the variable names to prevent problems with Angular dependency injection.
Here's my application.js.coffee
:
#= require jquery
#= require jquery_ujs
#= require unstable/angular
#= require underscore
#= require_self
#= require_tree ./vendor
#= require_tree ./configs
#= require_tree ./models
#= require_tree ./directives
#= require_tree ./filters
#= require_tree ./controllers
#= require_tree ./misc
window.app = angular.module "myApp", ["restangular"]
The minified restangular.min.js
file lives under the "javascripts/vendor" directory. It needs to be loaded after Angular and before all my controllers and models and stuff are loaded.
How can I tell Rails asset pipeline to skip minifying the restangular file and still load it the correct order?
Thanks!
Edit:
I found the solution and answered my own question.
<%= javascript_include_tag "vendor/restangular.min.js" %>
. The problem is that this file needs to be loaded after angular and before everything else. – user14412