Reading Ruby Metaprogramming inside Devise

It's hard to avoid using Devise in a Rails project. That's mostly because the ease of using it is hard to beat.Devise is incredibly configurable and that often means having code that can be hard to follow. Providing places in a library for configuration options and hooks for adding features is a difficult job.But metaprogramming in Ruby can be a flexible way to make a library easy to configure.Knowing metaprogramming helps you understand tools better, and if you don't know metaprogramming, you just might feel lost. Iterating over arrays and building up strings with define_method and other things going on requires a lot of mental effort to follow.The good news is that it's not as difficult to understand as you might expect when first reading it.
Reading Ruby Metaprogramming inside Devise #ruby #rails #rubyonrails #bosnia #programming #tutorials #rubydeveloper #railsdeveloper

Nezir Zahirovic

Freelance software developer Ruby On Rails (4 years) / MCPD .Net / C# / Asp.Net / CSS / SQL / (11 years)

related articles