Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: refactor DemoOptions component #1623

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

dschlabach
Copy link
Contributor

What changed? Why?
This PR refactors the DemoOptions component away from a switch/case and to a mapping pattern. I think this is appropriate for 2 reasons:

  1. Mapping is easier to read and maintain without stepping through nested logic.
  2. (more importantly) it will enable the next playground feature, the ability to copy "share links". This requires us to know which options are associated with which components, and this is much easier to do with an accessible mapping available.

Notes to reviewers

How has it been tested?

Base automatically changed from dms/refactor-playground to main November 14, 2024 20:00
Copy link

vercel bot commented Nov 14, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
onchainkit-coverage ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 15, 2024 7:24pm
onchainkit-playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 15, 2024 7:24pm
onchainkit-routes ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 15, 2024 7:24pm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants