AstonJ
Trending in Books
Isaak Tsalicoglou
Built for the curious, this isn’t your average programming book—it’s nearly 500 pages of hands-on mentorship beyond cod...
New
@hugobarauna and I (Alex Koutmos) have been hard at work on writing a book on Nerves that takes you from simply blinking LEDs to building...
New
Other Trending Topics
Hey, I’m Jesse and I’m the main contributor behind Dexter, a full-featured, lightning-fast Elixir LSP optimized for large codebases. It s...
New
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
Hello everyone. After busy few months I am happy to announce v0.1.0 of Emerge & Solve.
They are GUI (Emerge) and State management (S...
New
Corex is an accessible, unstyled UI component library for Phoenix that integrates Zag.js state machines using Vanilla JavaScript and Live...
New
Emily is an Elixir library that runs Nx computations on Apple’s MLX. Install it as the default Nx backend and Nx, defn, Axon, Nx.Serving,...
New
There has been a thread to discuss the Stack Overflow Developer Survey on this forum every year since 2018, so here’s yet another one for...
New
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #blog-post
- #phoenix_html
- #iex
- #graphql
- #ai
- #genstage
- #elixirconf-us
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #metaprogramming
- #security
- #hex











First 10 of 13 Posts
leifericf
I’ve already bought this book a few weeks ago, along with most of the other Elixir-related books at Pragprog. I think it’s a bit too advanced for me right now, but I’m looking forward to reading it after I’ve gotten through Programming Elixir and Programming Phoenix.
AstonJ
Let us know how you get on Leif! I also have the book, but haven’t got around to reading it yet
Anybody read it? Thoughts?
blatyo
I’ve read it and I liked it. It covers generating code from an external file, which is about 80% of the macro code I write. The section on generating an HTML DSL, is probably the least useful for me. I believe at some point it started using an actor to track changes, which I didn’t really like. The Phoenix router DSL is pretty interesting, but the patterns used there weren’t in the book. So, I recommend diving into the Phoenix, Plug, and Ecto code after reading the book. I’d say the book gave me the building blocks to read and understand those. Reading those, personally gave me a better idea of what’s possible.
pillaiindu
@chrismccord, are there any plans for 2nd edition of this book?
chrismccord
The book is still 100% relevant and there’s not yet a need for a 2nd edition as Elixir’s AST and metaprogramming features are fortunately quite stable. I think the only thing that needs updated in the book today is the
breakfeature of thewhilemacro will warn on null arity parensfrigidcode
$7.15 for the ebook, that’s a steal!
sfusato
I have just followed the book with no stumbling blocks along the way. I honestly expected to face some issues considering when the book was released, but other than some deprecation warnings which were expected, everything else was smooth sailing.
Solid book with very practical examples. Thank you Chris!
Ted
I picked up Metaprogramming Elixir during PragProg’s recent Christmas in July sale; the book is already modestly priced but was a steal with the discount.
I’m fairly new to Elixir, so my original intent was to read the book once I had a bit more exposure and experience under my belt.
But then I thought, “Well, I already have a rudimentary familiarity with macros from dabbling in Clojure (a lisp). I’ll be learning Ecto and Phoenix soon and I know there are some DSLs and
usegoing on there, so it’d be really nice to have some intuition about what’s happening under the hood. Let’s just take a little peek at the first chapter and see.”I was hooked.
Chris McCord’s clear writing style and obvious focus on reader ergonomics, e.g., repeating relevant bits of code, makes the book very readable and engaging.
Regarding content, there were plenty of moments where I thought, “wait, we’re going to do what next?! Okay, I’ve got time to read a few more pages…”
And, as I had hoped, the book covers DSLs and
use, but it also covered so much more.I was introduced to Elixir’s AST and the concept of macro hygiene, along with repeatable recipes for building DSLs and testing macros.
As an Elixir noob, I don’t think I’ll be writing my own for-real macros just yet, but I feel that I’ve gain a lot of valuable intuition about how the language works, which was my goal.
This is definitely a resource I’ll revisit once I get more experience.
Thank you @chrismccord!
Other notes:
I read the book cover-to-cover in about three days, mostly during lunch breaks and at bedtime.
I recommend reading the book start-to-finish.
I found the book to be e-reader friendly (Kindle Paperwhite, landscape).
AstonJ
That’s good to know! Bought the book ages ago, just haven’t got round to it yet..
Fl4m3Ph03n1x
Hello all, recently this book came into my attention, namely I am trying to do a macro that creates a module dynamically. Let’s say, something like this:
which would be generated by invoking:
Now I have checked the mini-video for the book:
And as an intro, it covers a lot. But after checking the index I have some questions: