Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

Metaprogramming in Ruby and Doing It Wrong

via YouTube

Overview

Explore metaprogramming in Ruby and its potential pitfalls in this 24-minute conference talk from Derbycon 2016. Delve into the fundamentals of Ruby, its strengths, and the concept of metaprogramming. Examine Rails Dynamic Finders and the "Three Deadly Metaprogramming Senses." Learn through practical examples, including the use of eval and method_missing. Discover common mistakes and their solutions, with a focus on ActiveRecord implementation. Gain insights into effective Ruby programming techniques and best practices for metaprogramming.

Syllabus

Introduction
What is Ruby
Whats best in Ruby
What is metaprogramming
Rails Dynamic Finders
Three Deadly Metaprogramming Senses
Why would we use this
Example
The Bad
The Fix
Constanteyes
EmployeeID
Payment Method
eval
Why use eval
Whats the fix
Method missing
ActiveRecord
I love Ruby
Questions

Reviews

Start your review of Metaprogramming in Ruby and Doing It Wrong

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.