From b0ad829685f18cf67cb1871b6d935b57bd2672cc Mon Sep 17 00:00:00 2001 From: Nick Schonning Date: Sun, 20 Nov 2022 23:47:11 -0500 Subject: [PATCH] fix: various typos (#22435) --- files/en-us/web/api/audioencoder/configure/index.md | 2 +- files/en-us/web/api/navigateevent/canintercept/index.md | 2 +- files/en-us/web/api/navigateevent/destination/index.md | 2 +- files/en-us/web/api/navigateevent/downloadrequest/index.md | 2 +- files/en-us/web/api/navigateevent/formdata/index.md | 2 +- files/en-us/web/api/navigateevent/hashchange/index.md | 2 +- files/en-us/web/api/navigateevent/index.md | 2 +- files/en-us/web/api/navigateevent/info/index.md | 2 +- files/en-us/web/api/navigateevent/intercept/index.md | 2 +- files/en-us/web/api/navigateevent/navigateevent/index.md | 2 +- files/en-us/web/api/navigateevent/navigationtype/index.md | 2 +- files/en-us/web/api/navigateevent/scroll/index.md | 2 +- files/en-us/web/api/navigateevent/signal/index.md | 2 +- files/en-us/web/api/navigateevent/userinitiated/index.md | 2 +- files/en-us/web/api/navigation/back/index.md | 2 +- files/en-us/web/api/navigation/cangoback/index.md | 2 +- files/en-us/web/api/navigation/cangoforward/index.md | 2 +- files/en-us/web/api/navigation/currententry/index.md | 2 +- files/en-us/web/api/navigation/entries/index.md | 2 +- files/en-us/web/api/navigation/forward/index.md | 2 +- files/en-us/web/api/navigation/index.md | 2 +- files/en-us/web/api/navigation/navigate/index.md | 2 +- files/en-us/web/api/navigation/reload/index.md | 2 +- files/en-us/web/api/navigation/transition/index.md | 2 +- files/en-us/web/api/navigation/traverseto/index.md | 2 +- files/en-us/web/api/navigation/updatecurrententry/index.md | 4 ++-- files/en-us/web/api/navigation_api/index.md | 4 ++-- .../web/api/navigationcurrententrychangeevent/from/index.md | 2 +- .../en-us/web/api/navigationcurrententrychangeevent/index.md | 2 +- .../navigationcurrententrychangeevent/index.md | 2 +- .../navigationcurrententrychangeevent/navigationtype/index.md | 2 +- files/en-us/web/api/navigationdestination/getstate/index.md | 2 +- files/en-us/web/api/navigationdestination/id/index.md | 2 +- files/en-us/web/api/navigationdestination/index.md | 2 +- files/en-us/web/api/navigationdestination/index/index.md | 2 +- files/en-us/web/api/navigationdestination/key/index.md | 2 +- .../en-us/web/api/navigationdestination/samedocument/index.md | 2 +- files/en-us/web/api/navigationdestination/url/index.md | 2 +- files/en-us/web/api/navigationhistoryentry/getstate/index.md | 2 +- files/en-us/web/api/navigationhistoryentry/id/index.md | 2 +- files/en-us/web/api/navigationhistoryentry/index.md | 2 +- files/en-us/web/api/navigationhistoryentry/index/index.md | 2 +- files/en-us/web/api/navigationhistoryentry/key/index.md | 2 +- .../web/api/navigationhistoryentry/samedocument/index.md | 2 +- files/en-us/web/api/navigationhistoryentry/url/index.md | 2 +- files/en-us/web/api/navigationtransition/finished/index.md | 2 +- files/en-us/web/api/navigationtransition/from/index.md | 2 +- files/en-us/web/api/navigationtransition/index.md | 2 +- .../web/api/navigationtransition/navigationtype/index.md | 2 +- files/en-us/web/api/window/navigation/index.md | 2 +- 50 files changed, 52 insertions(+), 52 deletions(-) diff --git a/files/en-us/web/api/audioencoder/configure/index.md b/files/en-us/web/api/audioencoder/configure/index.md index 17f8b77212a86f7..20c1ca52547aa2a 100644 --- a/files/en-us/web/api/audioencoder/configure/index.md +++ b/files/en-us/web/api/audioencoder/configure/index.md @@ -63,7 +63,7 @@ const init = { let config = { codec: "opus", sampleRate: 44100, - numberOfCannels: 2, + numberOfChannels: 2, bitrate: 128_000, // 128 kbps }; diff --git a/files/en-us/web/api/navigateevent/canintercept/index.md b/files/en-us/web/api/navigateevent/canintercept/index.md index c3a742cc5984391..445f6673be0d3a4 100644 --- a/files/en-us/web/api/navigateevent/canintercept/index.md +++ b/files/en-us/web/api/navigateevent/canintercept/index.md @@ -19,7 +19,7 @@ tags: browser-compat: api.NavigateEvent.canIntercept --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`canIntercept`** read-only property of the {{domxref("NavigateEvent")}} interface returns `true` if the navigation can be intercepted and have its URL rewritten, or `false` otherwise diff --git a/files/en-us/web/api/navigateevent/destination/index.md b/files/en-us/web/api/navigateevent/destination/index.md index 4f75521707d6cdd..6e011c034699a23 100644 --- a/files/en-us/web/api/navigateevent/destination/index.md +++ b/files/en-us/web/api/navigateevent/destination/index.md @@ -19,7 +19,7 @@ tags: browser-compat: api.NavigateEvent.destination --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`destination`** read-only property of the {{domxref("NavigateEvent")}} interface returns a {{domxref("NavigationDestination")}} object representing the destination being navigated to. diff --git a/files/en-us/web/api/navigateevent/downloadrequest/index.md b/files/en-us/web/api/navigateevent/downloadrequest/index.md index d99b907fa589379..6b1345071eb163c 100644 --- a/files/en-us/web/api/navigateevent/downloadrequest/index.md +++ b/files/en-us/web/api/navigateevent/downloadrequest/index.md @@ -19,7 +19,7 @@ tags: browser-compat: api.NavigateEvent.downloadRequest --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`downloadRequest`** read-only property of the {{domxref("NavigateEvent")}} interface returns the filename of the file requested for download, in the case of a download navigation (e.g. an {{htmlelement("a")}} or {{htmlelement("area")}} element with a `download` attribute), or `null` otherwise. diff --git a/files/en-us/web/api/navigateevent/formdata/index.md b/files/en-us/web/api/navigateevent/formdata/index.md index f8aa3602366afac..e933ef6e5445cf0 100644 --- a/files/en-us/web/api/navigateevent/formdata/index.md +++ b/files/en-us/web/api/navigateevent/formdata/index.md @@ -19,7 +19,7 @@ tags: browser-compat: api.NavigateEvent.formData --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`formData`** read-only property of the {{domxref("NavigateEvent")}} interface returns the {{domxref("FormData")}} object representing the submitted data in the case of a [`POST`](/en-US/docs/Web/HTTP/Methods/POST) form submission, or `null` otherwise. diff --git a/files/en-us/web/api/navigateevent/hashchange/index.md b/files/en-us/web/api/navigateevent/hashchange/index.md index 519b3578f0a3e2b..7570240fcab5847 100644 --- a/files/en-us/web/api/navigateevent/hashchange/index.md +++ b/files/en-us/web/api/navigateevent/hashchange/index.md @@ -19,7 +19,7 @@ tags: browser-compat: api.NavigateEvent.hashChange --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`hashChange`** read-only property of the {{domxref("NavigateEvent")}} interface returns `true` if the navigation is a fragment navigation (i.e. to a fragment identifier in the same document), or `false` otherwise. diff --git a/files/en-us/web/api/navigateevent/index.md b/files/en-us/web/api/navigateevent/index.md index 4e7c44bf7ebb331..307608f4c4408f4 100644 --- a/files/en-us/web/api/navigateevent/index.md +++ b/files/en-us/web/api/navigateevent/index.md @@ -17,7 +17,7 @@ tags: browser-compat: api.NavigateEvent --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`NavigateEvent`** interface of the {{domxref("Navigation API", "Navigation API", "", "nocode")}} is the event object for the {{domxref("Navigation/navigate_event", "navigate")}} event, which fires when [any type of navigation](https://github.com/WICG/navigation-api#appendix-types-of-navigations) is initiated (this includes usage of {{domxref("History API", "History API", "", "nocode")}} features like {{domxref("History.go()")}}). `NavigateEvent` provides access to information about that navigation, and allows developers to intercept and control the navigation handling. diff --git a/files/en-us/web/api/navigateevent/info/index.md b/files/en-us/web/api/navigateevent/info/index.md index 072b647d1b94c65..1b0b38bbd858ed8 100644 --- a/files/en-us/web/api/navigateevent/info/index.md +++ b/files/en-us/web/api/navigateevent/info/index.md @@ -19,7 +19,7 @@ tags: browser-compat: api.NavigateEvent.info --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`info`** read-only property of the {{domxref("NavigateEvent")}} interface returns the `info` data value passed by the initiating navigation operation (e.g. {{domxref("Navigation.back()")}}, or {{domxref("Navigation.navigate()")}}), or `undefined` if no `info` data was passed. diff --git a/files/en-us/web/api/navigateevent/intercept/index.md b/files/en-us/web/api/navigateevent/intercept/index.md index 7776033fa511a55..8c41e3256e87954 100644 --- a/files/en-us/web/api/navigateevent/intercept/index.md +++ b/files/en-us/web/api/navigateevent/intercept/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigateEvent.intercept --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`intercept()`** method of the {{domxref("NavigateEvent")}} interface intercepts this navigation, turning it into a same-document navigation to the {{domxref("NavigationDestination.url", "destination")}} URL. diff --git a/files/en-us/web/api/navigateevent/navigateevent/index.md b/files/en-us/web/api/navigateevent/navigateevent/index.md index ce5ebdcd857d771..7fd8350fdb983b0 100644 --- a/files/en-us/web/api/navigateevent/navigateevent/index.md +++ b/files/en-us/web/api/navigateevent/navigateevent/index.md @@ -17,7 +17,7 @@ tags: browser-compat: api.NavigateEvent.NavigateEvent --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`NavigateEvent()`** constructor creates a new {{domxref("NavigateEvent")}} object instance. diff --git a/files/en-us/web/api/navigateevent/navigationtype/index.md b/files/en-us/web/api/navigateevent/navigationtype/index.md index ee09d9ea28a3e61..5e193350997b404 100644 --- a/files/en-us/web/api/navigateevent/navigationtype/index.md +++ b/files/en-us/web/api/navigateevent/navigationtype/index.md @@ -19,7 +19,7 @@ tags: browser-compat: api.NavigateEvent.navigationType --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`navigationType`** read-only property of the {{domxref("NavigateEvent")}} interface returns the type of the navigation — `push`, `reload`, `replace`, or `traverse`. diff --git a/files/en-us/web/api/navigateevent/scroll/index.md b/files/en-us/web/api/navigateevent/scroll/index.md index 57822caedc55ee7..f3c538bb263a2b4 100644 --- a/files/en-us/web/api/navigateevent/scroll/index.md +++ b/files/en-us/web/api/navigateevent/scroll/index.md @@ -17,7 +17,7 @@ tags: browser-compat: api.NavigateEvent.scroll --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`scroll()`** method of the {{domxref("NavigateEvent")}} interface can be called to manually trigger the browser-driven scrolling behavior that occurs in response to the navigation, if you want it to happen before the navigation handling has completed. diff --git a/files/en-us/web/api/navigateevent/signal/index.md b/files/en-us/web/api/navigateevent/signal/index.md index 47d0f63020f16dd..93904437a59eb27 100644 --- a/files/en-us/web/api/navigateevent/signal/index.md +++ b/files/en-us/web/api/navigateevent/signal/index.md @@ -19,7 +19,7 @@ tags: browser-compat: api.NavigateEvent.signal --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`signal`** read-only property of the {{domxref("NavigateEvent")}} interface returns an {{domxref("AbortSignal")}}, which will become aborted if the navigation is cancelled (e.g. by the user pressing the browser's "Stop" button, or another navigation starting and thus cancelling the ongoing one). diff --git a/files/en-us/web/api/navigateevent/userinitiated/index.md b/files/en-us/web/api/navigateevent/userinitiated/index.md index 57a3fa502d3fd47..52df2b708767b1e 100644 --- a/files/en-us/web/api/navigateevent/userinitiated/index.md +++ b/files/en-us/web/api/navigateevent/userinitiated/index.md @@ -19,7 +19,7 @@ tags: browser-compat: api.NavigateEvent.userInitiated --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`userInitiated`** read-only property of the {{domxref("NavigateEvent")}} interface returns `true` if the navigation was initiated by the user (e.g. by clicking a link, submitting a form, or pressing the browser's "Back"/"Forward" buttons), or `false` otherwise. diff --git a/files/en-us/web/api/navigation/back/index.md b/files/en-us/web/api/navigation/back/index.md index ec046448f940683..b5ba8ef95dd796f 100644 --- a/files/en-us/web/api/navigation/back/index.md +++ b/files/en-us/web/api/navigation/back/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.Navigation.back --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`back()`** method of the {{domxref("Navigation")}} interface navigates backwards by one entry in the navigation history. diff --git a/files/en-us/web/api/navigation/cangoback/index.md b/files/en-us/web/api/navigation/cangoback/index.md index fda395223d53e4f..2e8df1ec4f6d695 100644 --- a/files/en-us/web/api/navigation/cangoback/index.md +++ b/files/en-us/web/api/navigation/cangoback/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.Navigation.canGoBack --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`canGoBack`** read-only property of the {{domxref("Navigation")}} interface returns `true` diff --git a/files/en-us/web/api/navigation/cangoforward/index.md b/files/en-us/web/api/navigation/cangoforward/index.md index dae4d57df47c62a..7196071690f79ff 100644 --- a/files/en-us/web/api/navigation/cangoforward/index.md +++ b/files/en-us/web/api/navigation/cangoforward/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.Navigation.canGoForward --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`canGoForward`** read-only property of the {{domxref("Navigation")}} interface returns `true` if it is possible to navigate forwards in the navigation history diff --git a/files/en-us/web/api/navigation/currententry/index.md b/files/en-us/web/api/navigation/currententry/index.md index c6f04e3fde8ab0c..daf2b534a62c455 100644 --- a/files/en-us/web/api/navigation/currententry/index.md +++ b/files/en-us/web/api/navigation/currententry/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.Navigation.currentEntry --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`currentEntry`** read-only property of the {{domxref("Navigation")}} interface returns a {{domxref("NavigationHistoryEntry")}} object representing the location the user is currently navigated to right now. diff --git a/files/en-us/web/api/navigation/entries/index.md b/files/en-us/web/api/navigation/entries/index.md index 3f66c55f3b854e8..3606d36829fbe31 100644 --- a/files/en-us/web/api/navigation/entries/index.md +++ b/files/en-us/web/api/navigation/entries/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.Navigation.entries --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`entries()`** method of the {{domxref("Navigation")}} interface returns an array of {{domxref("NavigationHistoryEntry")}} objects representing all existing history entries. diff --git a/files/en-us/web/api/navigation/forward/index.md b/files/en-us/web/api/navigation/forward/index.md index f636b270bc56e85..53bbb1e9179ae60 100644 --- a/files/en-us/web/api/navigation/forward/index.md +++ b/files/en-us/web/api/navigation/forward/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.Navigation.forward --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`forward()`** method of the {{domxref("Navigation")}} interface navigates forwards by one entry in the navigation history. diff --git a/files/en-us/web/api/navigation/index.md b/files/en-us/web/api/navigation/index.md index 4edd8bad7f90a04..67b12df84de9bc0 100644 --- a/files/en-us/web/api/navigation/index.md +++ b/files/en-us/web/api/navigation/index.md @@ -17,7 +17,7 @@ tags: browser-compat: api.Navigation --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`Navigation`** interface of the {{domxref("Navigation API", "Navigation API", "", "nocode")}} allows control over all navigation actions for the current `window` in one central place, including initiating navigations programmatically, examining navigation history entries, and managing navigations as they happen. diff --git a/files/en-us/web/api/navigation/navigate/index.md b/files/en-us/web/api/navigation/navigate/index.md index 91831bf94b245ce..1470f3d394e8781 100644 --- a/files/en-us/web/api/navigation/navigate/index.md +++ b/files/en-us/web/api/navigation/navigate/index.md @@ -17,7 +17,7 @@ tags: browser-compat: api.Navigation.navigate --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`navigate()`** method of the {{domxref("Navigation")}} interface navigates to a specific URL, updating any provided state in the history entries list. diff --git a/files/en-us/web/api/navigation/reload/index.md b/files/en-us/web/api/navigation/reload/index.md index 858cf864297456b..cba21b550b8978a 100644 --- a/files/en-us/web/api/navigation/reload/index.md +++ b/files/en-us/web/api/navigation/reload/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.Navigation.reload --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`reload()`** method of the {{domxref("Navigation")}} interface reloads the current URL, updating any provided state in the history entries list. diff --git a/files/en-us/web/api/navigation/transition/index.md b/files/en-us/web/api/navigation/transition/index.md index 96a5df38e8bd34c..5aeeadb01e212a7 100644 --- a/files/en-us/web/api/navigation/transition/index.md +++ b/files/en-us/web/api/navigation/transition/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.Navigation.transition --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`transition`** read-only property of the {{domxref("Navigation")}} interface returns a {{domxref("NavigationTransition")}} object representing the status of an in-progress navigation, which can be used to track it. diff --git a/files/en-us/web/api/navigation/traverseto/index.md b/files/en-us/web/api/navigation/traverseto/index.md index d27ec98717f6c37..76818e1540dd92b 100644 --- a/files/en-us/web/api/navigation/traverseto/index.md +++ b/files/en-us/web/api/navigation/traverseto/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.Navigation.traverseTo --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`traverseTo()`** method of the {{domxref("Navigation")}} interface navigates to the {{domxref("NavigationHistoryEntry")}} identified by the given {{domxref("NavigationHistoryEntry.key", "key")}}. diff --git a/files/en-us/web/api/navigation/updatecurrententry/index.md b/files/en-us/web/api/navigation/updatecurrententry/index.md index 787cebff0107fd0..974b95ab83c4632 100644 --- a/files/en-us/web/api/navigation/updatecurrententry/index.md +++ b/files/en-us/web/api/navigation/updatecurrententry/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.Navigation.updateCurrentEntry --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`updateCurrentEntry()`** method of the {{domxref("Navigation")}} interface updates the `state` of the {{domxref("Navigation.currentEntry","currentEntry")}}; used in cases where the state change will be independent from a navigation or reload. @@ -45,7 +45,7 @@ None (`undefined`). - `DataCloneError` {{domxref("DOMException")}} - : Thrown if the `state` parameter had values included in it that are not structured-clonable. - `InvalidStateError` {{domxref("DOMException")}} - - : Thrown if the {{domxref("Navigation.currentEntry")}} is `null`, i.e. there is no current history entry. This could occur for exaple if the current page is `about:blank`. + - : Thrown if the {{domxref("Navigation.currentEntry")}} is `null`, i.e. there is no current history entry. This could occur for example if the current page is `about:blank`. ## Examples diff --git a/files/en-us/web/api/navigation_api/index.md b/files/en-us/web/api/navigation_api/index.md index d95f4dc230e2bd4..ea13c8fc37d432e 100644 --- a/files/en-us/web/api/navigation_api/index.md +++ b/files/en-us/web/api/navigation_api/index.md @@ -19,7 +19,7 @@ browser-compat: - api.NavigateEvent --- -{{seecompattable}}{{DefaultAPISidebar("Navigation API")}} +{{SeeCompatTable}}{{DefaultAPISidebar("Navigation API")}} The **Navigation API** provides the ability to initiate, intercept, and manage browser navigation actions. It can also examine an application's history entries. This is a successor to previous web platform features such as the {{domxref("History API", "History API", "", "nocode")}} and {{domxref("window.location")}}, which solves their shortcomings and is specifically aimed at the needs of {{glossary("SPA", "single-page applications (SPAs)")}}. @@ -44,7 +44,7 @@ Once a navigation is initiated, and your `intercept()` handler is called, a {{do > **Note:** You can also call {{domxref("Event.preventDefault", "preventDefault()")}} to stop the navigation entirely for most [navigation types](/en-US/docs/Web/API/NavigateEvent/navigationType#value); cancellation of traverse navigations is not yet implemented. -When the `intercept()` handler function's promise fulfills, the `Navigation` object's {{domxref("Navigation/navigatesuccess_event", "navigatesuccess")}} event fires, allowing you to run cleanup code after a successful navigation has completed. If it rejects, meaning the navigation has failed, {{domxref("Navigation/navigateerror_event", "navigateerror")}} fires instead, allowing you to gracefully handle the failure case. There is also a {{domxref("NavigationTransition.finished", "finished")}} property on the `NavigationTransition` object, which fullfills or rejects at the same time as the aforementioned events are fired, providing another path for handling the success and failure cases. +When the `intercept()` handler function's promise fulfills, the `Navigation` object's {{domxref("Navigation/navigatesuccess_event", "navigatesuccess")}} event fires, allowing you to run cleanup code after a successful navigation has completed. If it rejects, meaning the navigation has failed, {{domxref("Navigation/navigateerror_event", "navigateerror")}} fires instead, allowing you to gracefully handle the failure case. There is also a {{domxref("NavigationTransition.finished", "finished")}} property on the `NavigationTransition` object, which fulfills or rejects at the same time as the aforementioned events are fired, providing another path for handling the success and failure cases. > **Note:** Before the Navigation API was available, to do something similar you'd have to listen for all click events on links, run `e.preventDefault()`, perform the appropriate {{domxref("History.pushState()")}} call, then set up the page view based on the new URL. And this wouldn't handle all navigations — only user-initiated link clicks. diff --git a/files/en-us/web/api/navigationcurrententrychangeevent/from/index.md b/files/en-us/web/api/navigationcurrententrychangeevent/from/index.md index 54c0d42552f6739..555e00544625f95 100644 --- a/files/en-us/web/api/navigationcurrententrychangeevent/from/index.md +++ b/files/en-us/web/api/navigationcurrententrychangeevent/from/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationCurrentEntryChangeEvent.from --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`from`** read-only property of the {{domxref("NavigationCurrentEntryChangeEvent")}} interface returns the {{domxref("NavigationHistoryEntry")}} that was navigated from. diff --git a/files/en-us/web/api/navigationcurrententrychangeevent/index.md b/files/en-us/web/api/navigationcurrententrychangeevent/index.md index c96c97d4a2c3c41..efe3625669b13b1 100644 --- a/files/en-us/web/api/navigationcurrententrychangeevent/index.md +++ b/files/en-us/web/api/navigationcurrententrychangeevent/index.md @@ -17,7 +17,7 @@ tags: browser-compat: api.NavigationCurrentEntryChangeEvent --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`NavigationCurrentEntryChangeEvent`** interface of the {{domxref("Navigation API", "Navigation API", "", "nocode")}} is the event object for the {{domxref("Navigation/currententrychange_event", "currententrychange")}} event, which fires when the {{domxref("Navigation.currentEntry")}} has changed. diff --git a/files/en-us/web/api/navigationcurrententrychangeevent/navigationcurrententrychangeevent/index.md b/files/en-us/web/api/navigationcurrententrychangeevent/navigationcurrententrychangeevent/index.md index b12ce6fca7f3e0b..9b53cd69956205e 100644 --- a/files/en-us/web/api/navigationcurrententrychangeevent/navigationcurrententrychangeevent/index.md +++ b/files/en-us/web/api/navigationcurrententrychangeevent/navigationcurrententrychangeevent/index.md @@ -16,7 +16,7 @@ tags: browser-compat: api.NavigationCurrentEntryChangeEvent.NavigationCurrentEntryChangeEvent --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`NavigationCurrentEntryChangeEvent()`** constructor creates a new {{domxref("NavigationCurrentEntryChangeEvent")}} object. diff --git a/files/en-us/web/api/navigationcurrententrychangeevent/navigationtype/index.md b/files/en-us/web/api/navigationcurrententrychangeevent/navigationtype/index.md index b432e10cb263784..9f797c8e652c7f4 100644 --- a/files/en-us/web/api/navigationcurrententrychangeevent/navigationtype/index.md +++ b/files/en-us/web/api/navigationcurrententrychangeevent/navigationtype/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationCurrentEntryChangeEvent.navigationType --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`navigationType`** read-only property of the {{domxref("NavigationCurrentEntryChangeEvent")}} interface returns the type of the navigation that resulted in the change. diff --git a/files/en-us/web/api/navigationdestination/getstate/index.md b/files/en-us/web/api/navigationdestination/getstate/index.md index db54e6e0ac2d1aa..5470c9c9d951df1 100644 --- a/files/en-us/web/api/navigationdestination/getstate/index.md +++ b/files/en-us/web/api/navigationdestination/getstate/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationDestination.getState --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`getState()`** method of the {{domxref("NavigationDestination")}} interface returns a clone of the developer-supplied state associated with the destination {{domxref("NavigationHistoryEntry")}}, or navigation operation (e.g. {{domxref("Navigation.navigate()", "navigate()")}}) as appropriate. diff --git a/files/en-us/web/api/navigationdestination/id/index.md b/files/en-us/web/api/navigationdestination/id/index.md index 892e365911d9588..88744a83fb5de56 100644 --- a/files/en-us/web/api/navigationdestination/id/index.md +++ b/files/en-us/web/api/navigationdestination/id/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationDestination.id --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`id`** read-only property of the {{domxref("NavigationDestination")}} interface returns the {{domxref("NavigationHistoryEntry.id", "id")}} value of the destination {{domxref("NavigationHistoryEntry")}} if the {{domxref("NavigateEvent.navigationType")}} is `traverse`, or `null` otherwise. diff --git a/files/en-us/web/api/navigationdestination/index.md b/files/en-us/web/api/navigationdestination/index.md index 48491c360bfb77e..57bf4288288a995 100644 --- a/files/en-us/web/api/navigationdestination/index.md +++ b/files/en-us/web/api/navigationdestination/index.md @@ -17,7 +17,7 @@ tags: browser-compat: api.NavigationDestination --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`NavigationDestination`** interface of the {{domxref("Navigation API", "Navigation API", "", "nocode")}} represents the destination being navigated to in the current navigation. diff --git a/files/en-us/web/api/navigationdestination/index/index.md b/files/en-us/web/api/navigationdestination/index/index.md index 460a49b6f6c7971..87a890bafcacef5 100644 --- a/files/en-us/web/api/navigationdestination/index/index.md +++ b/files/en-us/web/api/navigationdestination/index/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationDestination.index --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`index`** read-only property of the {{domxref("NavigationDestination")}} interface returns the {{domxref("NavigationHistoryEntry.index", "index")}} value of the destination {{domxref("NavigationHistoryEntry")}} if the {{domxref("NavigateEvent.navigationType")}} is `traverse`, or `-1` otherwise. diff --git a/files/en-us/web/api/navigationdestination/key/index.md b/files/en-us/web/api/navigationdestination/key/index.md index 8d08ef44c7b1b8a..ec6356313af6826 100644 --- a/files/en-us/web/api/navigationdestination/key/index.md +++ b/files/en-us/web/api/navigationdestination/key/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationDestination.key --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`key`** read-only property of the {{domxref("NavigationDestination")}} interface returns the {{domxref("NavigationHistoryEntry.key", "key")}} value of the destination {{domxref("NavigationHistoryEntry")}} if the {{domxref("NavigateEvent.navigationType")}} is `traverse`, or `null` otherwise. diff --git a/files/en-us/web/api/navigationdestination/samedocument/index.md b/files/en-us/web/api/navigationdestination/samedocument/index.md index 84b5f5f9d86d9eb..8684a547d9c4902 100644 --- a/files/en-us/web/api/navigationdestination/samedocument/index.md +++ b/files/en-us/web/api/navigationdestination/samedocument/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationDestination.sameDocument --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`sameDocument`** read-only property of the {{domxref("NavigationDestination")}} interface returns `true` if the navigation is to the same `document` as the current {{domxref("Document")}} value, or `false` otherwise. diff --git a/files/en-us/web/api/navigationdestination/url/index.md b/files/en-us/web/api/navigationdestination/url/index.md index 8723a19a7e714c1..9590cd95cfd88df 100644 --- a/files/en-us/web/api/navigationdestination/url/index.md +++ b/files/en-us/web/api/navigationdestination/url/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationDestination.url --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`url`** read-only property of the {{domxref("NavigationDestination")}} interface returns the URL being navigated to. diff --git a/files/en-us/web/api/navigationhistoryentry/getstate/index.md b/files/en-us/web/api/navigationhistoryentry/getstate/index.md index 62b6a009f96d0c4..2620ff2205e5b4c 100644 --- a/files/en-us/web/api/navigationhistoryentry/getstate/index.md +++ b/files/en-us/web/api/navigationhistoryentry/getstate/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationHistoryEntry.getState --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`getState()`** method of the {{domxref("NavigationHistoryEntry")}} interface returns a clone of the developer-supplied state associated with this history entry. diff --git a/files/en-us/web/api/navigationhistoryentry/id/index.md b/files/en-us/web/api/navigationhistoryentry/id/index.md index dc5bb7e5bb88640..affac017f7d3f0c 100644 --- a/files/en-us/web/api/navigationhistoryentry/id/index.md +++ b/files/en-us/web/api/navigationhistoryentry/id/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationHistoryEntry.id --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`id`** read-only property of the {{domxref("NavigationHistoryEntry")}} interface returns the `id` of the history entry. This is a unique, UA-generated value that always represents a specific history entry, useful to correlate it with an external resource such as a storage cache. diff --git a/files/en-us/web/api/navigationhistoryentry/index.md b/files/en-us/web/api/navigationhistoryentry/index.md index eff0a5350facc5f..58bfcb5b5ceb810 100644 --- a/files/en-us/web/api/navigationhistoryentry/index.md +++ b/files/en-us/web/api/navigationhistoryentry/index.md @@ -17,7 +17,7 @@ tags: browser-compat: api.NavigationHistoryEntry --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`NavigationHistoryEntry`** interface of the {{domxref("Navigation API", "Navigation API", "", "nocode")}} represents a single navigation history entry. diff --git a/files/en-us/web/api/navigationhistoryentry/index/index.md b/files/en-us/web/api/navigationhistoryentry/index/index.md index c39924594e28ea2..03ae4028472512c 100644 --- a/files/en-us/web/api/navigationhistoryentry/index/index.md +++ b/files/en-us/web/api/navigationhistoryentry/index/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationHistoryEntry.index --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`index`** read-only property of the {{domxref("NavigationHistoryEntry")}} interface returns the index of the history entry in the history entries list (that is, the list returned by {{domxref("Navigation.entries()")}}), or `-1` if the entry does not appear in the list. diff --git a/files/en-us/web/api/navigationhistoryentry/key/index.md b/files/en-us/web/api/navigationhistoryentry/key/index.md index f0654a2d1888190..1252ba762ef3811 100644 --- a/files/en-us/web/api/navigationhistoryentry/key/index.md +++ b/files/en-us/web/api/navigationhistoryentry/key/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationHistoryEntry.key --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`key`** read-only property of the {{domxref("NavigationHistoryEntry")}} interface returns the `key` of the history entry. This is a unique, UA-generated value that represents the history entry's slot in the entries list. It is used to navigate that particular slot via {{domxref("Navigation.traverseTo()")}}. The `key` will be reused by other entries that replace the entry in the list (that is, if the {{domxref("NavigateEvent.navigationType")}} is `replace`). diff --git a/files/en-us/web/api/navigationhistoryentry/samedocument/index.md b/files/en-us/web/api/navigationhistoryentry/samedocument/index.md index 4af97ceaeff2526..633d91737aff78b 100644 --- a/files/en-us/web/api/navigationhistoryentry/samedocument/index.md +++ b/files/en-us/web/api/navigationhistoryentry/samedocument/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationHistoryEntry.sameDocument --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`sameDocument`** read-only property of the {{domxref("NavigationHistoryEntry")}} interface returns `true` if this history entry is for the same `document` as the current {{domxref("Document")}} value, or `false` otherwise. diff --git a/files/en-us/web/api/navigationhistoryentry/url/index.md b/files/en-us/web/api/navigationhistoryentry/url/index.md index c69694e6edb2f0a..3c42023d096ae32 100644 --- a/files/en-us/web/api/navigationhistoryentry/url/index.md +++ b/files/en-us/web/api/navigationhistoryentry/url/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationHistoryEntry.url --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`url`** read-only property of the {{domxref("NavigationHistoryEntry")}} interface returns the absolute URL of this history entry. diff --git a/files/en-us/web/api/navigationtransition/finished/index.md b/files/en-us/web/api/navigationtransition/finished/index.md index a62be69cc121bd1..f85f58cddf3c22e 100644 --- a/files/en-us/web/api/navigationtransition/finished/index.md +++ b/files/en-us/web/api/navigationtransition/finished/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationTransition.finished --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`finished`** read-only property of the {{domxref("NavigationTransition")}} interface returns a {{jsxref("Promise")}} that fulfills at the same time the {{domxref("Navigation/navigatesuccess_event", "navigatesuccess")}} event fires, or rejects at the same time the {{domxref("Navigation/navigateerror_event", "navigateerror")}} event fires. diff --git a/files/en-us/web/api/navigationtransition/from/index.md b/files/en-us/web/api/navigationtransition/from/index.md index 2198a9ec993d6f7..c83990bcfe053d9 100644 --- a/files/en-us/web/api/navigationtransition/from/index.md +++ b/files/en-us/web/api/navigationtransition/from/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationTransition.from --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`from`** read-only property of the {{domxref("NavigationTransition")}} interface returns the {{domxref("NavigationHistoryEntry")}} that the transition is coming from. diff --git a/files/en-us/web/api/navigationtransition/index.md b/files/en-us/web/api/navigationtransition/index.md index fadea7e483b4f74..d20bf5885f9d51b 100644 --- a/files/en-us/web/api/navigationtransition/index.md +++ b/files/en-us/web/api/navigationtransition/index.md @@ -17,7 +17,7 @@ tags: browser-compat: api.NavigationTransition --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`NavigationTransition`** interface of the {{domxref("Navigation API", "Navigation API", "", "nocode")}} represents an ongoing navigation, that is, a navigation that hasn't yet reached the {{domxref("Navigation/navigatesuccess_event", "navigatesuccess")}} or {{domxref("Navigation/navigateerror_event", "navigateerror")}} stage. diff --git a/files/en-us/web/api/navigationtransition/navigationtype/index.md b/files/en-us/web/api/navigationtransition/navigationtype/index.md index c9257240dcb4463..7dd43bd21acd772 100644 --- a/files/en-us/web/api/navigationtransition/navigationtype/index.md +++ b/files/en-us/web/api/navigationtransition/navigationtype/index.md @@ -18,7 +18,7 @@ tags: browser-compat: api.NavigationTransition.navigationType --- -{{APIRef("Navigation API")}}{{seecompattable}} +{{APIRef("Navigation API")}}{{SeeCompatTable}} The **`navigationType`** read-only property of the {{domxref("NavigationTransition")}} interface returns the type of the ongoing navigation. diff --git a/files/en-us/web/api/window/navigation/index.md b/files/en-us/web/api/window/navigation/index.md index fc5d2ffc37d011b..40408f48060b109 100644 --- a/files/en-us/web/api/window/navigation/index.md +++ b/files/en-us/web/api/window/navigation/index.md @@ -14,7 +14,7 @@ tags: browser-compat: api.Window.navigation --- -{{APIRef}}{{seecompattable}} +{{APIRef}}{{SeeCompatTable}} The `navigation` read-only property of the {{domxref("Window")}} interface returns the current `window`'s associated {{domxref("Navigation")}} object.