I write here quick thoughts, ideas, tips, and learnings about programming, programmers, and building software. Most of my focus is on Ruby, Rails, Hotwire and everything about web applications.
Subscribe to my newsletter and never miss my upcoming articles
When thinking about testing, consider the following points:
You are not writing tests only for yourself but also for other developers who might join...
If you want to freeze strings in Ruby there are at least two ways to do this:
1) Adding the magic comment at the beginning of the file
How to get the class name
To get the class name:
def call = puts self.class.name
User.new.call #=> User
This will work even if the...
Examples of creating an enum type, renaming a value, deleting a value · Rails 7 introduced a new way to create enums in PostgreSQL, by adding create_enum...
I will try to explain what a class is in some other way, somehow quoting or paraphrasing in some parts what @steveklabnik said a very long time ago in...
A short opinionated guide about how to learn Ruby programming language · I think learning Ruby has three parts:
OOP + SOLID in Ruby