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.
Advanced Ruby Hash Techniques
This post shows some lesser-known but super useful Hash tricks. Learn how to lazily build lookup tables, raise exceptions when hash keys aren’t present and create infinitely nested hashes. http://blog.honeybadger.io/advanced-ruby-hash-techniques/
React.js - A guide for Rails developers
Nowadays, React.js has become one of the most popular JavaScript UI libraries. This extensive tutorial plugs it into the Rails stack to build frontend-powered applications, or you might say, Rails views on steroids.
Dynamic connectivity with Ruby
The dynamic connectivity problem uses a graph (a data structure) that maintains information about the relationship between its components. With this information the data structure can answer whether there is a connection between two objects or not.
Extending ActiveRecord association to cleanup your associations code
For some reason not many RoR developers know that they can extend ActiveRecord associations. This feature can be a great way to cleanup any relational code that is dependent on a parent resource. Here are few examples on how and when to use it: Extending ActiveRecord association to cleanup your associations code
LinkHum: humane link urlifier
LinkHum is humane, correct and customizable URL auto-linker in user-entered text. Just call LinkHum.urlify(any_text_with_urls) and there will be correct <a> tags. It tries hard to do the most reasonable thing even in complex cases.
Taskmanaging Your App, Part 1: Using Rake
Rake tasks: we all use them. But how exactly do they work? Where should you write them, and how do your tasks get interpreted? Here’s a blog post that dives down the rabbit hole of rake tasks, and how you can use them to task manage your applications!
How do I encrypt data in my database?
A beginner’s guide to keeping your data safe from those nasty bad guys:
Rebuilding Rails Model callbacks.
Where I start from scratch and (re)build the Rails Model callbacks. And some learnings along the way.
Lazy image creation with Carrierwave
firedev.com/posts/2015/lazy-image-creation-with-carrierwave/ [more inside]
Rails vs. Lotus
A comparison between the two Ruby web frameworks
Delegating to Query Objects through ActiveRecord scopes
Query Objects are a fairly well known concept in Rails. In this post, I’m explaining how you can use a Query Object as an ActiveRecord scope.
Exploring a weighted quick find union algorithm in Ruby
In this article I explore the weighted quick find union algorithm in Ruby. This is an algorithm useful to finding out whether node A is connected to node B. Think of a maze: Is there a solution from the start to the finish? Or a network: Can computer A speak to computer B.
From Rails scaffold to React step-by-step using react-rails
I prepared a simple repository showing a process of refactoring scaffolded Rails views to React components with built-in server-side rendering. It shows how simple you can switch from static Rails views to a dynamic-ready technology.
Maktoub 0.5.0 released
Version 0.5.0 of the Maktoub gem has been released. Maktoub is a simple rails engine for sending newsletters. [more inside]
I Love Ruby update
Added section “Hash, string and frozen string, their memory foot print” , get the book here
Staying Productive with the Volt Component Ecosystem
Episode 6 goes over how you can save time and keep code clean by using Volt components in your applications.
Be aware about the out-of-memory killer
One of the most important things for applications is stability. There are various hosting platforms that give you virtual servers, where you can run multiple services. There is no limit to the number of processes so it is up to you how much of their resources will be used. However, exceeding all available RAM memory can result in poor stability or even a server crash. This article gives you some basic knowledge about the out-of-memory system state. [more inside]
Fluxbox Apps Menu
If you are a Fluxbox user you can build your apps menu through this gem: Just some day ago i released the new 1.2.0 version.
Poltergeist watchdog - stop running out of memory
Using Rails? using acceptance testing? using PhantomJS with poltergeist? are your tests running too slow? are you running out of memory? well:
Printing images in the terminal with 9 lines of Ruby
I wrote a blog post about using terminal colours to render images in the terminal using Ruby. [more inside]
Rails Girls Łódź 2015
New post on the Ragnarson Blog - Rails Girls Łódź 2015 @_idengager
"yamlsh": Interactive REPL for authoring YAML files
I released a YAML authoring interactive REPL called yamlsh. Multi-language support (for typical I18n translation files) and cross-files consistency checks are in the works. Check it out!
eager_group - fix n+1 aggregate sql functions for rails
I just released eager_group 0.1.0, which fixes n+1 aggregate sql functions for rails, like querying average posts rating for each user, I also wrote a blog post to explain details