Answer the question
In order to leave comments, you need to log in
How to create another application in the assets folder in Rails?
Rails version 4.
There is an application in the assets folder (for js and css.)
The fact is that for one layout I want to use the current application, which includes certain files (css and js), and for another - another application, and naturally with another name, for example application_game, and there include the necessary files with require.
But if in the second layout-e I write: <%= stylesheet_link_tag 'application_game'
or <%= javascript_link_tag 'application_game'
- displays an error (exception). As far as I know such application_game is not registered.
But how can the problem be solved?
Answer the question
In order to leave comments, you need to log in
config.assets.precompile += %w( application_game.js )
stackoverflow.com/questions/16168166/rails-4-asset...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question