Post
related, i remember learning about the "as" from rebass around 2017 or 2018 but I see now that semantic ui had the initial version in 2016 random trivia: they called it "augmentation", before "composition" was cool, they later renamed it 😅 github.com/Semantic-Org...
github.comBreaking Changes: Add component augmentation by levithomason · Pull Request #414 · Semantic-Org/Semantic-UI-ReactFixes #403. This PR will add component augmentation.
Add augmentation to docs intro page
Add Dropdown as Button augmentation example related but beyond the scope of this PR
Investigate solving...
Yeah, Semantic UI was the first component library I saw that used this prop as a core API for all its components. I created ReAs (React As) as an experiment around this (github.com/diegohaz/reas). This project eventually became Ariakit.
I added support for TypeScript and arrays, and then I renamed the prop to `use`. This was before React hooks. This work now lives in a separate repo for posterity: github.com/diegohaz/reuse
github.comGitHub - diegohaz/reuse: ♻️ Reuse React components to create new ones♻️ Reuse React components to create new ones. Contribute to diegohaz/reuse development by creating an account on GitHub.