Skip to content

feat: persist active page in URL for shareable links#7

Open
DevLifeOfficial wants to merge 1 commit into
twilic:mainfrom
DevLifeOfficial:feat/persist-active-page-url
Open

feat: persist active page in URL for shareable links#7
DevLifeOfficial wants to merge 1 commit into
twilic:mainfrom
DevLifeOfficial:feat/persist-active-page-url

Conversation

@DevLifeOfficial

Copy link
Copy Markdown

Summary

Persist the active playground page in the URL using the page query parameter.

Changes

  • Read the initial page from the URL on load.
  • Update the URL when switching between "Encoded sizes" and "Schema-first".
  • Restore the active page from the URL on browser navigation.
  • Fall back to sizes when the query parameter is missing or invalid.

Related Issue

#4 (comment)

Closes #4

Type of Change

  • Bug fix
  • New feature
  • Refactor
  • Documentation
  • Chore / dependency update

Testing

  • Verified that ?page=schema opens the Schema-first page.
  • Verified that ?page=sizes (or no query parameter) opens the Encoded sizes page.
  • Verified that switching pages updates the URL.
  • Ran pnpm format.
  • Ran pnpm lint.

Checklist

  • Tests added or updated (optional)
  • Documentation updated (if applicable)
  • No breaking changes (or breaking changes are documented above)

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: persist active page in URL for shareable links

2 participants