Chapter 21Linking Modules: Behavio(u)rs and Use

When we wrote our OTP server, we wrote a module that started with code

 defmodule​ Sequence.Server ​do
 use​ GenServer
  ...

In this chapter we’ll explore what lines such as use GenServer actually do, and how we can write modules that extend the capabilities of other modules that use them.

Get Programming Elixir 1.2 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.