Three Things I Learned This Week - December 09 2016

  • Rails dropped its dependency on jQuery, rewriting all of it's unobtrusive JavaScript methods in pure JS. This change will be released as part of Rails 5.1.
  • Rails will support Webpack and Yarn as of 5.1, this is exciting to me as it should clear up a common pain point of pulling in JavaScript libraries and keeping them up to date in an easy way. Now we should be able to update JavaScript just like gems.
  • Rails 5 includes view helpers into controllers, so that they're available for Action Cable to publish messages from the controller. Rails 4 doesn't include helpers by default. The PushType CMS that I've been working with is Rails 4 and 5 compatible, and this was the first bug I ran into for Rails 4 support. It made the assumption that the helpers will be available. To fix, I had to include them into the needed class manually as part of my initialization script.

Written by Alex Brinkman who lives and works in Denver, but plays in the mountains.