← Graph

Why does Ruby UI avoid slots?

question 3 connections

Audience question noting that Ruby UI favors many small atomic components rather than the common slots-based approach used by ViewComponent. Seth Horsley answers that slots aren't a big thing in the JavaScript world many front-end developers come from and that slots 'limit the functionality' — they tightly couple a micro component to the parent component, so that micro component can't be reused elsewhere.

answer_summary
Slots aren't common in JavaScript and tie micro-components to a single parent, preventing reuse elsewhere.
question Why does Ruby UI avoid slots?
about
Ruby UI project
About Ruby UI's API philosophy.
question Why does Ruby UI avoid slots?
about
Contrasts with the slots pattern used by ViewComponent.
question Why does Ruby UI avoid slots?
asked_at
Audience Q&A.

Provenance