One way, perhaps not the ''best practise'' way, would be to do:
<%= javascript_tag ''your_js_file'' if
RAILS_ENV==''production'' %>
That might do it.
On Feb 17, 2:38 pm, kevin evans
<kwev...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:> Anyone have some tips on the best way to do this? I want to
> conditionally include some javascript only if the app is running in
> production mode..
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---