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.
Ruby Plus Podcast Episode 14
Listen to this week’s Ruby Plus Podcast Episode 14
A digest of new articles interesting to Rubyists
We’ve decided to make public our regular digests of articles worth reading by the whole team. In our #1 public digest there are 10 links to interesting articles from around the web, from Ruby 3 new concurrency model (links to Koichi’s original slides from RubyKaigi) through ActiveRecord lazy evaluation to learning CSS Flexbox in a few minutes.
How to include methods in the JSON representation of a model
Here’s a short blog post about using active_model_serializers, so you can all get rid of your as_json, to_json and serializable_hash monkey patches:
https://christoph.luppri.ch/articles/2016/09/22/how-to-include-methods-in-the-json-representation-of-a-model/
Better File Uploads with Shrine: Attachment
In the previous post I talked about the foundation of Shrine’s design. In this post I want to show you Shrine’s high-level interface for attaching uploaded files to model instances, and what advantages it has over other file upload libraries. Read the post here.
Ruby Facets: a short & sweet podcast about Ruby news
Short story: The first episode of Ruby Facets was just published. Long story: Why Ruby Facets exists and why Ruby5 doesn’t.
The art of defining products
A post about how to turn your idea into a project [more inside]
A couple of words about interactors in Rails
Do you prefer skinny models or skinny controllers? That’s a mean thing, indeed, to ask incorrect question on purpose. mkdev.me mentor Ivan Shamatov writes about how to use Interactors, using an order in e-commerce app as an example. https://mkdev.me/en/posts/a-couple-of-words-about-interactors-in-rails
Decompose your rails controllers for ultimate power
I’ve published new gem. It offers a new approach to manage growing complexity in rails applications. gem: https://github.com/antulik/pagelet_rails
Custom Database Cleaner for ActiveRecord connections
Custom database cleaner for cleaning multiple databases in Rails applications when using dynamic ActiveRecord connections.
Static Times Q&A about Octopod ‘n’ Podcasting w/ Jekyll w/ Stefan Haslinger
Hello, In the Static Times Q&A series let’s welcome Stefan Haslinger - author of Octopod - a free Jekyll extension (theme and scripts) that lets you publish your own radio shows in minutes w/ Ruby ;-) Questions (and answers) include: Q: How did you get started with podcasting? ++ Q: Do you remember - how did you find out/ get started with Jekyll? Did you try out any alternatives static (web) site builders e.g. Middleman, Nanoc, etc.? ++ Q: Jekyll and Podcasting - How (and why) did you get started / end up writing your own Jekyll Podcasting extension (Octopod)? ++ Q: Can you highlight some of the great Octopod features / goodies? ++ Q: How do you handle the upload / sync of the big media files (audio recordings)? ++ Q: What’s next for Octopod? Any plans for the future? ++ Q: Any tips on getting started with Octopod? Read the full Q&A » Cheers. Happy Podcasting. Happy Jekylling.
Why I wrote "massager" gem?
I have been working with a lot of different data sources lately and wanted to have a DSL that is capable of handling the conversions/coercions and type checks on the boundries of my application. Here is the blog post with reasoning behind “massager” gem: http://janjiss.com/why-i-wrote-massager-gem/
DRYing Up Your Ruby Module
You know about the Don’t Repeat Yourself principle, but how do you actually apply it in production code? Let’s refactor a Ruby module and see the DRY principle in action.
What’s Happening in Your Ruby Application?
Learn about the ObjectSpace module to help you debug & explore your application’s status: http://www.blackbytes.info/2016/09/object-space/
Auto-Labeling Pull Requests
As our engineering team continues to grow it’s becoming difficult to keep track of all the changes that we’re introducing to our codebase every day. Check out how we auto-label our pull requests based on the files that they touch.
A Definition Of Magic
Rails and Ruby are often accused of being “too magical,” but what does that mean, exactly? Here, I’d like put forward a definition of magic.
Is Elixir programming really that hard?
How to survive in a post-apocalyptic Elixir world devoid of classes, objects and methods that we’ve grown to depend on so much? Written from a perspective of Ruby & Rails developer without prior experience in functional programming. Read more on the Phoenix on Rails blog.
35x faster and 4x less memory hungry PDF rendering using Prawn instead of wkhtmltopdf
Look how a solution based on Prawn compare to one based on wkhtmltopdf when comes to generating invoices.
Hello, Jekyll! & Hello, Minima! Theme - Get Started in 60 Seconds w/ GitHub Pages
Hello, I’ve put together two 1-2-3 steps getting started guides in 60 seconds for using Jekyll with GitHub Pages. #1 - Henry’s Hello, Jekyll! - start from scratch with a blank page / site: Step 1 - Create the Jekyll Configuration / Settings File ++ Step 2 - Create the Index Page ++ Step 3 - Create the Master Layout ++ See the Henry’s Hello, Jekyll! theme / repo for the live action. [more inside]
Fighting custom actions in Rails controllers
By now I have never seen a rails project which doesn’t have custom actions in rails controllers. And that makes me upset. Here I’m going to describe my thoughts about custom actions, why people use them, why I hate them and how to deal with them. http://blog.active-bridge.com/fighting-custom-actions-in-rails-controllers
Usage of SQL and NoSQL Database’s in Single Rails Application
There are distinctive reasons why you should think about having various databases in your Ruby on Rails application. In my situation, I expected to store large quantities of data. Read here : Usage of SQL and NoSQL Database’s in single rails application(MySQL, PostgreSQL and MongoDB)
Rails 5 blogs and the art of story telling
Between October 31,2015 and Sep 5, 2016 we wrote 80 blogs on changes in Rails 5. This blog captures what we learned along the way.
RubyKaigi 2016 - summary
Last week I attended RubyKaigi, the most prestigious Ruby conference in the world. Find out what it was like and what went down. Read More
Microservices using Rails, HTTP & RabbitMQ
This blog post explains why sometimes microservices play very important role in some situations over the monolithic app. [more inside]
[Screencast] Authorization with Pundit
Prevent unauthorized access to your application with Pundit; an authorization library for Ruby on Rails which restricts what resources a given user is allowed to access. https://www.driftingruby.com/episodes/authorization-with-pundit