The Ruby and Rails community linklog
Made a library? Written a blog post? Found a useful tutorial? Share it with the Ruby community here or just enjoy what everyone else has found!
Submit a post
Post Preview
Note: Only the first pargraph is shown on the front page and overly long paragraphs may be broken up.
Ruby on Rails: Send emails with style
Most of us had already at some point to deal with the pain of sending HTML formatted emails using Ruby on Rails. Here you’ll find some solutions - Ruby on Rails: send emails with style
Speeding up Docker image build process of a Rails application
We reduced the Docker image building time of our Rails application from 10 minutes to 5 minutes by re-using bundler cache and by precompiling assets. Read the full story at our blog -
Double announcement: Jekyll-Timeago release and mini_i18n launch!
The first one, is a new release (v0.10.0) of the Jekyll-Timeago plugin, a little library to display distances of dates in words. Now ships with a more flexible i18n system and a more useful integration with Jekyll, allowing for example, set a different language per page. [more inside]
Exploding Rails giveaway
Want to learn how to build Rails apps with rom-rb and dry-rb? We’re giving away three copies of Exploding Rails from Ryan Bigg! [more inside]
[Screencast] Performance improvements in Rails using derailed_benchmarks
A quick look into the derailed_benchmarks gem, and how I use it to try to improve performance on Rails apps:
The Definitive RSpec Tutorial (With Examples)
Would you like to learn how to write tests for your Ruby applications using RSpec? Then this is article is for you!
Optimizing batches in Rails for a healthcare directory based on event-sourcing
A very practical optimization about ActiveRecord batches strategy when dealing with heavily joined queries:
tty-box - draw various boxes in terminal emulators
The tty-box gem helps you draw boxes around your content in terminal window. You can easily wrap and add padding to your content. It supports Unicode and multi-width characters out of the box (you see what I’ve done here ;-) Enjoy!
Ruby gem for OpenStreetMap API
I wrote simple ruby gem for using OpenStreetMap API [more inside]
Do not put Rails on the whale
Having trouble using Rails inside docker? Just give up:
Six Tips for Mastering your Procfile
Not strictly Ruby, but definitely useful if you deploy a Rails app to Heroku. It’s a quick read with some simple ways to leverage a Procfile to run your application processes.
How to Test Ruby Modules With Rspec
When you have a module that you include in other classes, the way you test it might not be obvious. Testing ruby modules will be easier after you read this tutorial.
Instant page loads with Turbolinks and prefetch
Turbolinks can dramatically speed up your website by not requiring and evaluating CSS and Javascript for each pageload. Instantclick will preload any links when you hover over them instead of when you click. What about having Turbolinks AND “instant clicks”? [more inside]
Numbers and Class Hierarchy in Ruby
In this article we’re going to explore the following topics:
sportdb Gem/Library Guide - Working w/ Football CSV Files - English Premier League
Hello, I’ve written-up a hands-on getting started guide for the new sportdb text library / gem. Let’s build the standings table for the English Premier League (EPL) for the 2017/18 season from all 380 matches in the comma-separated values (.csv) format. Full article titled “Working with CSV Files”. Enjoy the beautiful game with ruby.
3 Practical Examples Of Ruby Blocks
Have you ever wanted to learn how to use Ruby blocks in a practical way? In this video I’ll show you how:
Top Spree E-Commerce Extensions to Build Ruby E-Commerce Store
Spree E-Commerce is a complete, scalable, API-driven open source E-commerce framework built with Ruby on Rails. Spree is well suited to serve as a custom technology platform to build any type of an E-commerce application.
Spreadsheet Architect celebrates 800 Stars on GitHub!
I would like to celebrate and share with you that my most popular open source project, Spreadsheet Architect, has recently surpassed 800 Stars on GitHub. It makes me happy to know that it has helped many people in their Ruby programming endeavours. I hope this library continues to help you the same way it has aided me. What is this gem? Spreadsheet Architect is a library that allows you to create XLSX, ODS, or CSV spreadsheets super easily from ActiveRecord relations, plain Ruby objects, or tabular data. https://github.com/westonganger/spreadsheet_architect
The ENV object
In this article we’re going to explore the following topics:
Let vs. Let! vs. Instance Variables in RSpec
A common source of confusion when using RSpec is whether to use let, let!, or an instance variable, for storing state.
Doing more on reads vs writes
What do you like more in your application? Handling complexity when reading the data or when updating it? Let’s compare 3 different approaches.