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.
Adding Google Analytics to a Rails 5 / Turbolinks 5 app
Step by step instructions for setting up Google Analytics on a Rails 5 / Turbolinks app.
Using racecar to Consume Kafka messages in Rails
In this article Using racecar to Consume Kafka messages in Rails , I setup a simple producer using waterdrop gem and consume the messages using racecar. I also illustrate how to troubleshoot problems when running multiple kafka consumers consuming messages from the same topic using kafkacat.
prettier for Ruby
prettier-ruby is now ready for folks to try out! Please give it a shot and open up issues if you run into any!
Inheritance on-the-fly with Ruby on Rails
Today we’re going to talk about the way that Ruby on Rails ensure the compatibility of your migrations when you upgrade Ruby on Rails. [more inside]
Leaving Breadcrumbs in your Progressive Web App with Stimulus.js
This is a tutorial on using Stimulus.js to create a breadcrumbs in your progressive web app. PWAs can be displayed without any browser chrome, including back and forward buttons, so your app is now responsible for some kind of back and forth mechanism.
Avoiding Junk-Drawer Classes in Ruby
We’ve all seen classes bloat over time and become junk-drawers of loosely-related methods. This post discusses the underlying cause of the junk-drawer problem and how we can avoid it by taking a cue from Elixir. [more inside]
Tips for running free dynos on Heroku in 2019
I see a lot of confusion around Heroku’s free dynos, so I wrote a guide. Here’s everything you need to know, and how to make the most of Heroku’s free offerings. [more inside]
Creating the simplest CMS in the world with Rails and Google docs
simple solution for content driven websites.
Top 5 Things to Build while Learning Web Development
When learning web development it can be fustrating to know what to focus your efforts on. Especially when you are trying to land that first job or freelance gig. This post is designed to expose those learning web development where to focus their energy.
Opal-RSpec v0.7 finally released!
Opal-RSpec is a port to Opal of the glorious RSpec TDD library. Runs your specs entirely in the browser or on Node.js. The new release brings compatibility with Opal v0.11 and a new CLI and folder structure.
Preload, Eager Load, Includes and Joins in Ruby on Rails
Preload, Eager Load, Includes and Joins in Ruby on Rails
Journey of leaving comfort Ruby world to understand native extensions — introduction
Hello, I’m starting new series of articles explaining Ruby native extensions by complete example for everyone interested in this mysterious world of Ruby ecosystem.
Spree Commerce 3.7 with new REST API v2 released!
Completely new REST API v2 powered by Netflix fast_jsonapi gem, API documentation in OpenAPI (Swagger) with Postman import support, Service Oriented Architecture - those are only the highlights of this huge release. [more inside]
The Enumerable module in #Ruby: Part I
As Ruby is a fully object-oriented programming language, even traversing a collection can be accomplished directly through the collection itself.. SEE MORE
sruby - Simple, Secure & Solid Ruby (for Blockchain Contract Scripts)
Hello, I’ve published a new red paper that introduces the new sruby version / flavor. sruby - short for simple, secure & solid ruby - is a subset of mruby that is a subset of “classic” ruby and lets you run contract / transaction scripts on the blockchain / world computer. Happy transacting with sruby. Cheers. Prost.
[Screencast] What the RegEx?
In this episode, we look at different ways to use pattern matching with Regular Expressions in Ruby. https://www.driftingruby.com/episodes/what-the-regex
How to handle layout changes when using HTTP caching in Rails
It is very easy to get started with HTTP caching in Rails, but there are a few small things you need to watch out for. Handling layout changes is one of those things, and I explain how to do that in this article.
Universum - next gen world computer runtime - run contracts in ruby
Hello, I’ve updated Universum - a next generation ethereum-like world computer runtime - that lets you run contract scripts / transactions in ruby on the blockchain. Cheers. Prost. PS: See the Programming Crypto Contracts Step-by-Step guide / book for more contract samples in ruby (e.g. satoshi_dice.rb, ponzi_governmental.rb and many more).
Using the Find module to count the LOC of a Rails application
In this article, we’re going to describe the Find module and use it for counting the Lines of Code of a Rails application.. SEE MORE
Rails Isn’t Dead, Not Even Close. 6 Rails Advantages Keeping It Alive
Why should you be using Ruby on Rails for e-commerce? Answers inside that piece, complete with a shop tutorial on top of Refinery CMS. Code snippets, repo, and demo included! [more inside]
Programming Crypto Contracts w/ Ruby - New Chapter: Ponzi Governmental - Win Jackpot!
Hello, I’ve added a new chapter to the (free online) step-by-step guide / booklet titled “Programming Crypto Blockchain Contracts (with Ruby) Step-by-Step Book / Guide”. Let’s look at the p@nzi governmental - a real world case study - last creditor / investor (before collapse) wins the jackpot! Cheers. Prost.
Rails handles large number of nested routes better than Sinatra
I ran Jeremy Evans routing benchmark and here are the numbers.
Rails includes vs Join
When I started learning Rails, I was always in a state of confusion about using includes or joins, because both are used in almost same scenario. Includes uses eager loading whereas joins uses lazy loading. Both are used when certain operations are meant to be performed on associated tables. And here comes the difference.
RSpec Mocks and Stubs in Plain English
One of the most common questions I see from beginners to Rails testing is what mocks and stubs are and when to use them. https://www.codewithjason.com/rspec-mocks-stubs-plain-english/ If you’re confused about mocks and stubs, you’re not alone. In my experience very few people understand them. In this post I’ll attempt to help clarify the matter, particularly in the context of Rails/RSpec. [more inside]