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

View Transitions: adding data-astro-reload forces browser default behavior for navigation #8217

Merged
merged 1 commit into from
Aug 24, 2023

Conversation

martrapp
Copy link
Member

THIS IS THE SECOND TRY for the failed PR #8153

Changes

Specify data-astro-reload (no value) on an anchor element to force the browser to ignore view transitions and fall back to default loading.

This is helpful when navigating to documents that have different content-types, e.g. application/pdf, where you want to use the build in viewer of the browser.
Example: <a href='/my.pdf' data-astro-reload>...</a>

Testing

e2e test added

Docs

@changeset-bot
Copy link

changeset-bot bot commented Aug 24, 2023

🦋 Changeset detected

Latest commit: a26280b

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added the pkg: astro Related to the core `astro` package (scope) label Aug 24, 2023
@matthewp matthewp merged commit c37632a into withastro:main Aug 24, 2023
13 checks passed
@martrapp martrapp deleted the mt7947 branch August 25, 2023 15:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pkg: astro Related to the core `astro` package (scope)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants