I am writing a new JavaScript templating system for Rails as a plugin.
I want to use the extension “.fjs”. When a user “wants.js” in a
respond_to block I would first like to look for a .fjs file and render
it with my new templating system. If an .fjs file is not present then
look for .rjs file and render with the rjs templating system.
Is this easily possible through the Rails API or is this going to be
hacking the Rails core?
Any pointers how to do this or get started would be greatly appreciated.
I wanted to write exactly what MinusMOR does (i just picked on letter
away in the extension). Wrapping JavaScript in Ruby seems like a bad
idea after using RJS for even a short time. I hope a bunch of Railers
jump on the MInusMOR bandwagon. Great stuff!
This was literally the next project on my list. I am happy it already
has been done.