MDN self-hosted library · e01.org

NavigationTransition: committed property

Navigation API

Open notebook · 1 cells web-api-instance-property upstream source

Navigation API

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

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

Specifications

Browser compatibility

See also