NavigationTransition: committed property

The committed read-only property of the NavigationTransition interface returns a Promise that fulfills when Navigation.currentEntry is updated and the new URL is displayed in the browser, marking the navigation as committed. This happens after all precommit handlers for the navigation are fulfilled.

The committed promise rejects if any precommit handler rejects.

Value

A Promise that resolves to undefined.

Examples

js
async function lockInNavigation() {
  await navigation.transition.committed;
  // Navigation has committed successfully
}

Specifications

Specification
HTML
# dom-navigationtransition-committed

Browser compatibility

See also