We're sorry but this page doesn't work properly without JavaScript enabled. Please enable it to continue.
Feedback

A Look at Hooks

Formal Metadata

Title
A Look at Hooks
Title of Series
Number of Parts
67
Author
License
CC Attribution - ShareAlike 3.0 Unported:
You are free to use, adapt and copy, distribute and transmit the work or content in adapted or unchanged form for any legal and non-commercial purpose as long as the work is attributed to the author in the manner specified by the author or licensor and the work or content is shared also in adapted form only under the conditions of this
Identifiers
Publisher
Release Date
Language
Producer
Production PlaceCincinnati

Content Metadata

Subject Area
Genre
Abstract
Ruby has several methods that are invoked implicitly under certain circumstances. These methods are called "hooks", and they provide points to extend behavior. While hooks might seem like "spooky action at a distance", they can be really powerful. In fact, hooks are one of the primary ways that Ruby provides for meta-programming. Unfortunately, Ruby's hooks are not all documented very well. We'll take a look at what hooks are available and how to use them. We'll also talk about when to avoid using hooks and provide some tips on how to troubleshoot when hooks are involved.