Analytics Js & a Mash of Interesting Rails Stuff

Analytics.js

I don’t know whether this library is very common, but it definitely shows a lot of promise:

Segmentio’s Analytics.js

It provides provider-agnostic hooks to route to analytics services. They also have a hosted version where the analytics services can be changed without touching the code. Looks really clean and neat.

Nice video: to_proc

This video by CooperPress explains in a very clear fashion how to use the “to_proc” feature of Ruby (and understand some weird code you might come across). It is also well worth it to subscribe to their other videos.

Faster Rails partial rendering and caching

I sure will try out this gem (multi_fetch_fragments) to optimize Rails when I get to that point of my work…

Indexes in Rails databases

Extremely good article by Tom Ward on using indexes in rails associations. An excellent guide to determine what indexes your app should include (no more, no less).

Comments