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.
Your Clever Code is a Jewel-Encrusted Lobster
Over the weekend, I wrote a quick post about the similarities between “clever” code and a very special lobster.
Let's keep frontend outside of Ruby
I wrote my thoughts about why I believe it’s always better to keep backend and frontend separate.
Representable 2.2 Is More Than 50% Faster Than The World!
Representable 2.2 is significantly faster when parsing and rendering objects to and from documents in REST APIs. Get a quick overview about some benchmarks and the major changes in my blog post.
Verifying PubSub Services (like Redis) from Rails
Verifying PubSub services can be tricky, since subscribers loop over to listen messages. This is one way to test these services, using threads. [more inside]
Class Methods and Singleton Methods
Singleton Methods Demystified. What are they and where do they live?
Using domain events as success/failure messages
When you publish an event on success make sure you publish on failure too [more inside]
Rake task to drop and reseed database in Rails
If you need to drop your databases and run migrations from scratch, here’s a simple rake task that will do this: rake db:reseed.
Handling RabbitMQ consumer failures with maxretry handler
Example of handling RabbitMQ consumer failures using great gem called ‘sneakers’ and ‘maxretry’ handler for requeue and retry messages after failure.
Reflections on Coaching at Rails Girls
Last week I took part in a Rails Girls seminar in Tel Aviv. It was a great experience sharing my passion for coding with people who really wanted to learn. Read some of my thoughts on the event.
Switching From Unicorn to Puma on Heroku is Easy!
It’s as easy as 3 changes and you’re good to go!
Start using ES6 with Rails today
I really liked new ECMAScript syntax. I wanted to try it out in my Rails project, but it wasn’t that easy. See my guide on 2 ways to get ES6 in Rails:
Ruby Object Model : Class Methods
Class Methods Demystified
tty-platform released
tty-platform offers query methods for detecting different operating systems. This is a new component for tty library for bootstrapping development of terminal apps.
Introducing read models in your legacy application
Simple walktrough how to introduce read models in your legacy application. Check this out:
Connecting Some Models To A Different Database In Rails
We extracted a few models into their own application and database for shared use between other applications. Heres how to setup such a thing:
Functional Programming with Ruby
Wanna try functional programming, but don’t want to learn a new language? I made it simple by introducing basic concepts of FB with Ruby examples! Have a look:
New Version Ruby On Windows Guides Released
New version of Ruby On Windows Guides is released. There are number of changes compared to previous version. ConEmu is used for better and easier work in Command Prompt, Uru is now main Ruby version manager. Default Ruby is now 2.2.1, Rails is updated to 4.2.1 and chapters about SQlite, MS SQL, MySQL and PostgreSQL all use latest versions.
Speed Up Your Rails Views By Deferring Changes
Having your views doing calculations to determine your output could be very costly in page load time. Speed up your site by first deferring some dynamic content and thereby allowing performance increases with more caching.
Howitzer v1.1.0 released
Hello. I am happy to announce Howitzer v1.1.0. For details, please see Changelog
DeepEnumerable
A library for manipulating nested collections:
Complex Static Sites on Heroku
Hosting a complex static site on Heroku is a lot easier than it seems.
ANN Lotus v0.3.1
RESTful nested resource(s), dirty tracking and timestamps for entities, improved code generators, bug fixes. -
Ruby’s instance_exec method
instance_exec is a method you can use to change the “scope” of a block. One of the great advantages of doing this is that it can make your code more readable, particularly when writing a Domain Specific Language (DSL). So how does instance_exec work and why would you ever want to write a DSL? [more inside]
Asset Pipeline In Rails 3.1.0
Asset pipeline provides a framework to concatenate and minify or compress JavaScript and CSS assets. It also adds the ability to write these assets in other languages such as CoffeeScript, Sass and ERB. In Rails 3.1, the rails asset pipeline is enabled by default.