Advanced Functional Programming with Elixir (PragProg)

Use advanced functional programming principles, practical Domain-Driven Design techniques, and production-ready Elixir code to build scalable, complex systems from simple, reusable components.

Joseph Koski @JKWA

Series editor: Sophie DeBenedetto @SophieDeBenedetto
Developmental editor Adaobi Obi Tulton @aotulton

Combine advanced functional programming concepts with production-ready Elixir and proven domain-driven design techniques to write cleaner, more thoughtful software. You’ll explore foundational ideas like equality, ordering, predicates, monoids, and monads—then go beyond syntax as you develop intuition for composing logic, modeling behavior, and growing systems. With a focus on maintainable, declarative code over theory, you’ll gain practical, composable patterns you can apply right away.

Get ready to manage crowds, adjust priorities, and keep everyone safe in FunPark, a place that never sits still. Your job is to model that complexity and build the systems that keep everything running smoothly, even as the business team is still figuring out what they want and the experts keep rewriting the rules.

Using core abstractions—equality, ordering, predicates, monoids, and monads—you’ll break problems into small, composable pieces that are both well-behaved and easy to combine. Rather than getting bogged down in theory or formal proofs, you’ll dive into real-world Elixir—using protocols, structs, and pattern matching to express shared behavior across your domain. Along the way, you’ll build the vocabulary and mental models you need to organize complex logic, supported by a production-ready open-source library you can use, extend, and explore in your own projects.

Whether you’re an Elixir developer mastering functional programming or a functional programmer exploring Elixir, you’ll discover how to write code that’s easier to reason about—and create systems that stay understandable, even as they grow.


Joseph Koski is a software engineer with expertise in functional programming, domain-driven design, and safety-critical systems. He created the Funx library, bringing tools like monads to Elixir. He writes at joekoski.com, sharing insights on functional programming, real-time systems, and using Elixir to solve complex, reliability-focused problems.


Don’t forget you can get 35% off with your Devtalk discount! Just use the coupon code “devtalk.com" at checkout :+1:

4 Likes

Oooo this looks interesting! Just in time for when I want to get back into reading again!

I guess this book would be the next step after Learn Functional Programming with Elixir (PragProg)?

2 Likes

Will add to my reading list :slight_smile:

2 Likes

Learn Functional Programming with Elixir introduces the basics such as immutability, recursion, and higher-order functions.

Advanced Functional Programming with Elixir, on the other hand, builds mastery of functional patterns such as monoids, predicates, and monads as tools for thinking about structure and behavior. It is not a sequel per se, but a next step for those looking to deepen how they reason about code.

4 Likes

Would like to deepen my understanding of functional programming and would prefer to do it via Elixir. This is going on the list.

2 Likes

Thanks! I also recommend Domain Modeling Made Functional by Scott Wlaschin. It’s written in F#, but the lessons go beyond the language. I’ve tried to follow his lead in Advanced Functional Programming with Elixir . It’s written in Elixir, but the concepts are useful no matter what language you prefer.

2 Likes

Bought it yesterday and read chapter 1. Definitely will look forward to it bridging a gap in my knowledge as an experienced Elixir developer but not an experienced FP developer per se. Tried to learn FP via Haskell a couple of times but as I had no real need to use the language I dropped it too quickly.

2 Likes

I can sympathize. Learning Haskell can be frustrating. Most books and tutorials focus on syntax, not functional programming itself, which can leave you feeling adrift.

My goal was to light the path. Not to make functional programming easy (it’s not), but to help the reader focus their attention, avoid common missteps, and move forward with purpose.

3 Likes

Exciting! I’d be happy to see more real-world use case examples. My disappointments with Haskell references stem from how heavily they focus on the syntactic side.

3 Likes

Thank you for the suggestion. I am going to try to read Domain Modeling Made Functional first, then your book. :slight_smile:

3 Likes

Really interesting book, read chap 1 and 2.

1 Like

Hello! Would you recommend learning Haskell to understand functional programming better?

1 Like

Thanks! Chapter 3 is on monoids, which is one of my favorite patterns.

1 Like

Hmm.. if you’d like a deep dive into how FP patterns are derived from first principles, then Haskell, with its origins in academia, is the best place to go. The syntax is an uphill battle, but with LLMs, some of that frustration goes away.

1 Like

maybe this is the best time to read :upside_down_face:? too scared seeing the word “monad”

1 Like

Monads aren’t as scary as they look. I excerpted the start of the monad chapter if you’d like a peek. You can also lean on your LLM and the Funx tutor to ask questions as you go. At their core, monads are just a structured way to handle control flow, deciding what happens next in a computation.

3 Likes

awesome! :folded_hands:t4:

1 Like

@JKWA This looks very interesting! What books/courses would you recommend to someone who hasn’t formally studied functional programming but wants to start from the ground up before diving into your book?

So far, two books have been mentioned in this thread:

  • Learn Functional Programming with Elixir by Ulisses Almeida
  • Domain Modeling Made Functional by Scott Wlaschin

Do you have any other recommendations? In what order would you suggest reading them?

1 Like

Maybe not (strictly) functional but a classic worth reading is Structure and Interpretation of Computer Programs (SICP).

2 Likes

I would like to add Introduction to Functional Programming by Richard Bird and Philip Wadler

1 Like