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
Note: Only the first pargraph is shown on the front page and overly long paragraphs may be broken up.
v3.0.0 of your favorite spreadsheet library for Ruby, Spreadsheet Architect, is now released! For those that don’t already know Spreadsheet Architect is the bee’s knee’s for creating any format of spreadsheets within your Ruby or Rails projects. Now you know. Check out the Changelog for the sweet deets. https://github.com/westonganger/spreadsheet_architect
The Ruby Enumerable module deserves the top spot in the popularity contest. It packs so many great methods that it’s hard to think of an application that wouldn’t use it.
What are some of the stats around Ruby on Rails developer hiring in 2018? We examine an article by Yoel Blum. [more inside]
HTTPX is an http protocol client library in ruby which supports concurrent requests (using HTTP/2 and HTTP/1 protocol features), modular features and a simple API.
A simple approach to ensure that user can only modify their own records in a Ruby on Rails application. [more inside]
Have you ever struggled to place a method that seems like it belongs equally well in either of two different classes? In this newly-free screencast from the RubyTapas archives, you’ll see a new way to think about ambiguously-homed methods.
Before 5.2 it was not possible to write multiple entries to cache store in one shot even though cache stores like Redis has MSET command to set multiple keys in a single atomic operation. Rails 5.2 adds method that allow us to set multiple entries at once. [more inside]
Almost everything in Ruby is an object, and errors are no exception. Learn to create your own exceptions in AppSignal Academy # 18 https://blog.appsignal.com/2018/07/03/custom-exceptions-in-ruby.html
Arrays are probably the most popular data structure you’re going to use in Ruby. Learn what you can do with them and how to use them effectively. Read it here
A quide on how to deploy your Ruby on Rails app to Dokku, including the core aspects of setting a hosting account, swap, configuration, installing plugins, SSH deploy, redeploy and management.
A new article in the series about Golang from Rubyist’s perspective. http://zonov.me/golang-for-rubyists-part-7-ruby-and-golang-methods-comparison/
When you have tests that sometimes pass but also sometimes fail, it’s often because one of your supposedly independent tests isn’t tearing down properly. Manual debugging could take hours – but
rspec --bisect can help narrow down the cause really quickly. https://medium.com/@scottm/find-the-cause-of-randomly-failing-tests-with-rspec-bisect-dfe9ee2a70c2
Operator precedence might be one of the most confusing parts of the Ruby language. Even the docs recommend you just use
||. Read it here
This post is from the considered harmful series where we talk about wrong way of doing things.
In this tutorial, we will use the DDD (documentation-driven development) approach to writing a kind-of-mocked Rails API application. We will set up extensive documentation testing using a combination of Rails API (our framework of choice), API Blueprint (as a language describing our API endpoints) and Dredd (a tool to test API endpoints against documentation). Read it here