Re: [csswg-drafts] [css-view-transitions-2] Script event on old Document for cross-document ViewTransitions (#8785)

> What does the event give us that we don't get from URL matching in @view-transition and types?

We haven't yet decided whether the URL matching for `@view-transition` will be based on the initial URL or post redirect one. Since we're not adding the "to" property yet, the question can be deferred. If we decide to use the post redirect URL for this then we should have an easy equivalent script hook.

> If the page really wants to run some JS before the transition capture, couldn't they do so by listening to navigations from the navigation API?

The `navigate` event runs before we dispatch the navigation request with the initial URL. I don't know of any script API today which provides the post redirect URL.

-- 
GitHub Notification of comment by khushalsagar
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/8785#issuecomment-1816939652 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Friday, 17 November 2023 19:02:34 UTC