I apologizes if the topic is wrong.
I really love Ruby on Rails, though I've started lately, because it forces me to be clean coding.
But I'd like to be cleaner creating JS functions on different files, to be called when needed.
This the model:
function_1.js -> function_1()
function_2.js -> function_2()
function_3.js -> function_1.run(), function_2.run()
how to do that?
I have already tried in creating new files but them seem not to communicate to each other.