What are state machines? (feat. Ash Framework)

State machines are important data models to be used in situations with a series of known states and well-defined transition rules. From light switches to ca...

What are state machines? (feat. Ash Framework)
Code and Stuff
5.6K views • Jul 20, 2025
What are state machines? (feat. Ash Framework)

About this video

State machines are important data models to be used in situations with a series of known states and well-defined transition rules.

From light switches to cars, vim, and even payment processing—these come up more often than you might think.

Elixir's Ash Framework has a package that makes managing state machines easy, consistent, and well-documented.


Links:
Screen recording software I use (affiliate): https://screen.studio/@Yy75o
Project Repo: https://github.com/ChristianAlexander/money_pit (look at git tags for pre- and post-refactor)
Ash Framework: https://ash-hq.org/
Ash State Machine: https://hexdocs.pm/ash_state_machine
Ash Oban: https://hexdocs.pm/ash_oban


Timestamps:
State machines? - 00:00
Demo - 02:10
What's Ash? - 02:35
Demo code walkthrough - 03:27
Refactoring to ash_state_machine - 07:16
State permissions in one line - 09:06
Other Ash niceties - 10:18


YouTube Academy Competition: #TeamHailey

Tags and Topics

Browse our collection to discover more content in these categories.

Video Information

Views

5.6K

Likes

293

Duration

12:28

Published

Jul 20, 2025

User Reviews

4.6
(1)
Rate:

Related Trending Topics

LIVE TRENDS

Related trending topics. Click any trend to explore more videos.

Trending Now