Ruby on Rails
Thursday, April 4, 2013
On Thursday, April 4, 2013 1:14:01 PM UTC+1, Peter wrote:
Hello Everyone,Can anyone please describe the relationship of javascript-runtime to Ruby on Rails? In Mac OSX, I do not get this error, but in Linux for every new project generated by "rails new", I get:play$ rails s//.rvm/gems/ruby-2.0.0-p0/gems/execjs-1.4.0/lib/execjs/ runtimes.rb:51:in `autodetect': Could not find a JavaScript runtime. See https://github.com/ sstephenson/execjs for a list of available runtimes.I know the solution; either install therubyracer or nodejs gems. But I am not sure I understand fully why it works. If I install this in a production environment server, I do not need either one of these. And my browser definitely interprets javascript built in. So how does this fit in to everything? Is my premise incorrect? Thank you.
There are asset pipeline dependencies here: for example uglifyjs (for minifying javascript) and coffeescript are both written in javascript. Both of these two things happen serverside (almost: you can compile the assets somewhere other than your deployment machines, and copy the finished product either to the deployment machines or to the CDN of your choice)
Fred
-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/uC2PPtH4k8UJ.
For more options, visit https://groups.google.com/groups/opt_out.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment