Home Rails 4 + Sprockets: Allowing the use of js.erb files
Reply: 0

Rails 4 + Sprockets: Allowing the use of js.erb files

user549
1#
user549 Published in August 15, 2018, 11:15 am

I am attempting to use ES6 syntax in my Rails 4 app and have had some success between the use of sprockets-es6 (0.9.2), sprockets-rails (3.0.4) and sprockets (3.6.0).

The only issue I'm having is that my files need to end in .es6 in order to enable proper compilation and I'd like to be able to use a .es6.erb or .js.erb file type to allow me to use embedded ruby <%= foo %>.

Does anyone know of a way around this?

You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.297547 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO