"Making Impossible States Impossible" by Richard Feldman
elm-confYouTube ↗
Further reading 1
Caption notes
Richard Feldman uses Elm CSS and a survey app to show how data structures can encode application rules. He replaces separate lists of prompts and responses with a single list in which each item holds a prompt and an optional response. To support navigation, he makes the current question part of the full sequence alongside the previous and remaining questions. He also suggests exposing accessor functions so that the internal representation can change without callers depending on its fields.
Archived captions (transcription method unspecified) ↗Original passages · 2
make impossible model States impossible to representyou cannot have a response without a corresponding prompt