I am new to Rails and still don't understand the resource container ...
I want a
views/product/product.js
starts automatically after
views/product/index.html.erb
was displayed for DRY reasons.
Is there a place in the asset pipeline that calls the model.js file after loading any or partial model.erb file?
I know how to do it manually, and dumped
app/assets/javascripts/product.js
but then I have to call the doSomethingAfterPageload () method in a new, show. delete etc. Even better if it works for partial ones.
source
share