Let’s play with Wikidata (query.wikidata.org) Return 20 items which are instance of human which have a twitter account: SELECT ?item ?twitter WHERE { ?item wdt:P31 wd:Q5 . ?item wdt:P2002 ?twitter . } LIMIT 20 Or all Nobel Peace laureates:

Ruby on Rails & other tech
redirect_back in Rails 5
redirect_back in Rails 5 is handy: redirect_back(fallback_location: whatever_path) fallback_location is used when HTTP_REFERER is not present. In Rails 4 we had to use redirect_to :back and rescue RedirectBackError: class MyController < ApplicationController rescue_from ActionController::RedirectBackError, with: :redirect_to_default def action redirect_to :back end… Read More ›
My first post in Medium
I wrote a post in Medium about AgreeList.com and why I think it matters. You can also find the code of AgreeList on GitHub.
Rails 5 tutorial: How to create a Chat with Action Cable
David Heinemeier Hansson recorded a screencast building a chat with Action Cable in Rails 5. Here we have a summary: # app/controllers/rooms_controller.rb # app/views/rooms/show.html.erb # app/view/messages/_message.html.erb rails g channel room speak # app/channels/room_channel.rb And on app/assets/javascripts/cable.coffee we add: # app/assets/javascripts/channels/room.coffee… Read More ›
Template Method Pattern
The Template Method Pattern consists of a method that is used as a default value. It is then overwritten in classes that inherit or include it: This way classes that inherit from Cycle can overwrite default_chain, removing the need of super… Read More ›
Avoid the need for comments
As comments are not executable, they are easily out of date. They are a form of decaying documentation. If the code inside a method needs a comment, you probably can extract the code into a new method whose name explains what… Read More ›
Practical Object-Oriented Design in Ruby
This book is great: http://www.poodr.com
Duplication is far cheaper than the wrong abstraction
Sandy Metz said that if you find yourself passing parameters and adding conditional paths through shared code, the abstraction is incorrect. Then you should go back: Re-introduce duplication by inlining the abstracted code back into every caller. Within each caller,… Read More ›