rails generate paperclip_database:migration getting protected method `migration_file_name’ error

Quick fix (put this in application.rb or similar in order to run the rails generate paperclip_databasee:migration command): module PaperclipDatabase module Generators class MigrationGenerator public :migration_file_name end end end There are two errors causing this error, one in paperclip and one in paperclip_database. Not sure what changes to Rails 4 caused this, but the issue is […]

CoffeeScript event handlers only working after page refresh

I was able to find a resolution on StackOverflow to fix an event handler. I initially opted to added $(document).ready(…) and $(document).on(‘page:load’, …) handlers as follows: ready = -> $(‘form’).on ‘click’, ‘.clickable_class’, (event) -> # doStuff # added lines: $(document).ready(ready) $(document).on(‘page:load’, ready) However, another answer recommended adding the jquery-turbolinks instead. Browsing the source code, it […]