{"product_id":"elixir-metaprogramming-a-practical-guide-to-mastering-macros-dsls-and-compile-time-code-transformation-9798273139008","title":"Elixir Metaprogramming: A Practical Guide to Mastering Macros, DSLs, and Compile-Time Code Transformation","description":"\u003cp\u003e • Author(s): Daniel C. Price\u003cbr\u003e • Publisher: Independently Published\u003cbr\u003e • Publisher Imprint: Independently Published\u003cbr\u003e • BISAC: Programming - Compilers\u003c\/p\u003e\u003cp\u003e\u003c\/p\u003e\u003cp\u003eHave you ever looked at a Phoenix.Router or Ecto.Schema and wondered, \"How does that \u003ci\u003eactually\u003c\/i\u003e work?\" You see use, plug, get, and schema, and they just \u003ci\u003efeel\u003c\/i\u003e like part of the language, but you know they are not.\u003c\/p\u003e\u003cp\u003eThis \"black box\" is where many developers get stuck. You've probably used quote and unquote for simple tasks, but you are not sure how to combine them into a powerful tool. I've been there.\u003c\/p\u003e\u003cp\u003eThis book is designed to turn that \"black box\" into a clear, glass one. I will show you that the \"magic\" of Elixir's best libraries is actually a set of simple, repeatable patterns that \u003ci\u003eyou\u003c\/i\u003e can learn and master. You will move from being confused by this power to being in complete control of it.\u003c\/p\u003e\u003cb\u003eWhat's inside\u003c\/b\u003e\u003cp\u003eThis book is a step-by-step journey, and here is a look at what we will cover: \u003c\/p\u003e\u003cul\u003e\n\u003cli\u003e\n\u003cb\u003eSee Your Code as Data: \u003c\/b\u003e A deep look at the Abstract Syntax Tree (AST), the one concept that makes everything else possible.\u003c\/li\u003e\n\u003cli\u003e\n\u003cb\u003eMaster \u003c\/b\u003e\u003cb\u003equote\u003c\/b\u003e\u003cb\u003e and \u003c\/b\u003e\u003cb\u003eunquote\u003c\/b\u003e\u003cb\u003e: \u003c\/b\u003e Learn to read and \u003ci\u003ebuild\u003c\/i\u003e new code programmatically.\u003c\/li\u003e\n\u003cli\u003e\n\u003cb\u003eWrite Your First Macro: \u003c\/b\u003e A step-by-step guide to building defmacro, understanding the \"Two Timelines\" of compile-time and runtime.\u003c\/li\u003e\n\u003cli\u003e\n\u003cb\u003eControl Macro Hygiene: \u003c\/b\u003e Understand how Elixir protects your variables and how to \u003ci\u003eintentionally\u003c\/i\u003e break that protection with var!.\u003c\/li\u003e\n\u003cli\u003e\n\u003cb\u003eGenerate Functions: \u003c\/b\u003e Learn to use module attributes and compile callbacks (@before_compile) to build powerful, multi-part modules.\u003c\/li\u003e\n\u003cli\u003e\n\u003cb\u003eBuild Your Own DSL: \u003c\/b\u003e A hands-on, multi-part case study where we build a mini-testing framework (like ExUnit) from scratch.\u003c\/li\u003e\n\u003cli\u003e\n\u003cb\u003eDemystify \u003c\/b\u003e\u003cb\u003euse\u003c\/b\u003e\u003cb\u003e and \u003c\/b\u003e\u003cb\u003e__using__\u003c\/b\u003e\u003cb\u003e: \u003c\/b\u003e Learn how libraries like Phoenix inject code into your modules and how to build your own.\u003c\/li\u003e\n\u003cli\u003e\n\u003cb\u003eDebug Like a Pro: \u003c\/b\u003e Master the tools (IO.inspect, Macro.to_string, Macro.expand) for troubleshooting your compile-time code.\u003c\/li\u003e\n\u003cli\u003e\n\u003cb\u003eDeconstruct Real-World Code: \u003c\/b\u003e We'll pull apart Phoenix.Controller, Phoenix.Router, and Ecto.Schema to prove it is \u003ci\u003eall\u003c\/i\u003e just macros.\u003c\/li\u003e\n\u003c\/ul\u003e\u003cb\u003eWho it's meant for\u003c\/b\u003e\u003cp\u003eThis book is \u003ci\u003enot\u003c\/i\u003e for the brand-new Elixir developer. This book is for \u003cb\u003eyou\u003c\/b\u003e, the intermediate-to-advanced Elixir programmer who has hit a plateau.\u003c\/p\u003e\u003cp\u003eThis book is for you if: \u003c\/p\u003e\u003cul\u003e\n\u003cli\u003eYou are comfortable with defmodule and def.\u003c\/li\u003e\n\u003cli\u003eYou want to understand the \"how\" behind Phoenix and Ecto, not just the \"what.\"\u003c\/li\u003e\n\u003cli\u003eYou want to write your own powerful, clean, and reusable libraries.\u003c\/li\u003e\n\u003cli\u003eYou are ready to move from being an Elixir \u003ci\u003euser\u003c\/i\u003e to an Elixir \u003ci\u003earchitect\u003c\/i\u003e.\u003c\/li\u003e\n\u003c\/ul\u003e\u003cp\u003eStop letting metaprogramming be a \"black box.\" The most powerful parts of Elixir are open to you. \u003cb\u003eThis book is the key.\u003c\/b\u003e Turn your confusion into confidence, and start writing the code you've always wondered how to build.\u003c\/p\u003e\u003cp\u003e\u003cb\u003eGet your copy today\u003c\/b\u003e and unlock the true potential of Elixir.\u003c\/p\u003e","brand":"Independently Published","offers":[{"title":"Paperback","offer_id":48218288685207,"sku":"9798273139008","price":2089.0,"currency_code":"INR","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0666\/3471\/1191\/files\/9798273139008.webp?v=1788743544","url":"https:\/\/atlanticbooks.com\/products\/elixir-metaprogramming-a-practical-guide-to-mastering-macros-dsls-and-compile-time-code-transformation-9798273139008","provider":"Atlantic Books","version":"1.0","type":"link"}