metaprogramming
CommunityMaster Ruby metaprogramming to build DSLs.
Authorbastos
Version1.0.0
Installs0
System Documentation
What problem does it solve?
Ruby metaprogramming enables developers to create flexible interfaces, reduce boilerplate, and build expressive DSLs. This guide helps you understand when and how to use metaprogramming techniques to craft maintainable APIs.
Core Features & Use Cases
- Dynamic method creation with define_method for runtime behavior
- Method_lookup customization via method_missing and respond_to_missing?
- ClassEval/ModuleEval and instance_eval for targeted scope and DSLs
- Hooks, callbacks, and DSL creation for expressive configurations
- Practical examples: building a tiny DSL, dynamic attribute accessors, and small domain-focused languages
Quick Start
Describe a minimal Ruby DSL using metaprogramming to configure a class.
Dependency Matrix
Required Modules
None requiredComponents
references
💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: metaprogramming Download link: https://github.com/bastos/ruby-plugin-marketplace/archive/main.zip#metaprogramming Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.