Sinatra is a Ruby web framework that lets you build apps with less code. It has an expressive syntax and is less complex than other frameworks like Rails. In this article, we’ll use Sinatra to make a URL shortening app and learn how to use this powerful tool.
From concept to execution, join me on a step-by-step journey through the process of crafting your own functional Ruby gem.
Uncover the inner workings of Ruby on Rails with our dive into the Params hash—an essential component for handling HTTP requests. From query params to avoiding injection, this article will elevate your understanding of Rails, providing you with the tools to create more secure and efficient web applications.
Dive into the world of enums to discover how they can streamline your code and make it more readable. Learn best practices, how to add and manage enum attributes, and take advantage of Rails' built-in features to efficiently manage finite sets of values in your models.
Explore the future of asset pipelines in Rails with Propshaft! Discover how this cutting-edge technology enhances the management and delivery of assets while simplifying your development workflow.
This article will teach you how to monitor Ruby errors without using a service like Honeybadger! Learn about Ruby's built-in errors, how to use log levels and tagging to customize the log output, display errors on the front-end, and more.
Working with invoices, contracts, or just reading your favorite mystery thriller—whatever the case, PDF files are everywhere. Learn how to work with PDFs in Ruby.
Feature flags are used all across the tech industry to test code at scale; this article explores how to integrate them into your Ruby on Rails application using the Flipper gem.
This article explores how to use markdown in Ruby. Learn how to use two popular Ruby libraries—Redcarpet and Kramdown—to parse markdown and create a simple documentation app using Redcarpet and Sinatra.
Ractor is Ruby's new Actor-like concurrency abstraction—it lets execute code in parallel without worrying about thread safety. This article is an excellent introduction to Ractors and how to begin using them in your Ruby code.
People complain that Ruby isn't fast. Stripe—one of the world's largest and most influential Ruby shops—is working hard to change that. In addition to type-checking, this article explores a new, ahead-of-time Ruby compiler Stripe is developing as a part of their Sorbet Ruby Gem.
In this article, Julie Kent discusses using associations in Rails when the underlying data model spans multiple databases. We didn't even know Rails could do this!
The conclusion to Alex Braha Stoll's 5-part series on how to build a toy programming language in Ruby.
Ruby on Rails is one of the most popular Ruby frameworks, but it's not the only one. Hanami 2.0 is faster than Rails and packed with exciting features—it might be the tool you need for your next project!
Data structure and type validations are so essential in modern Rails apps. You've probably used Active Model validations and strong parameters, but did you know there is a better way? This article introduces the dry-schema gem—a faster alternative to the defaults!
Generators are a powerful feature you can use to automate routine tasks in Rails—but do you know how to make your own? This article explores Rails generators in depth, including how to build a generator from scratch.
Accepting user input is critical to modern Rails applications, but without validations, it can cause problems. In this article, learn how to use
ActiveModel validations to ensure the data you process is safe.
Want to deploy a Rails app with Docker and AWS, but not sure where to start? AWS Fargate simplifies the convoluted process of deploying Docker on Amazon's Elastic Container Service (ECS). It's also a good alternative to Heroku.
Getting data into your database is easy, but querying large datasets is challenging—especially without the right indexes. Pavel Tkachenko teaches how to write performant SQL queries with EXPLAIN and ANALYZE.