← Graph

Accordion of Complexity

concept 4 connections

Phlex-flavored design philosophy articulated by Joel Drapper during the talk: a component system should let you 'expand and contract' the complexity of a component's API. Illustrated with a table component implemented three ways: (1) a one-call `table(data)` that iterates rows and columns itself; (2) a set of granular atomic components (table, thead, tr, td, …) that wrap each HTML tag and are composed heavily — roughly how Ruby UI works; (3) a higher-level DSL `table(users) { column(:name) { |u| … } }` that iterates an enumerable and executes a proc per column. The advantage of (3) is being able to think of tables purely in terms of columns, with headers and bodies guaranteed to stay in sync.

category
pattern
about
Accordion of Complexity concept
Drapper uses Stephen Margheim's accordion-of-complexity framing to describe Literal's incremental safety layers.
about
Accordion of Complexity concept
Joel Drapper presents Phlex's accordion-of-complexity for a table component.
about
Accordion of Complexity concept
Talk concludes by framing Yippee's whole design around letting developers expand or collapse layers as needed — 'playing the accordion'.
related_to
Accordion of Complexity concept
The named layers exist precisely so they can be collapsed (1:1:1 Active-Record-style) or expanded (3 models for 1 table) as needed.

Provenance

Read by
2 extractions