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

Redesign WebView2 TOC & clarify article titles #3124

Open
wants to merge 49 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
caeaca8
start updating toc from pr 2725
mikehoffms Apr 9, 2024
c019f7e
Apply changes from PR 2725
mikehoffms Apr 10, 2024
77347df
show more full titles in toc
mikehoffms Apr 11, 2024
0028215
move deploy samples to deploy toc bucket
mikehoffms Apr 11, 2024
f292062
consistent article titles for samples
mikehoffms Apr 11, 2024
c9436a9
promote "Web and native interop" in TOC
mikehoffms Apr 11, 2024
9da2e53
Working with --> Use
mikehoffms Apr 11, 2024
fb98d26
catch up What's New's w/ "main"
mikehoffms Apr 11, 2024
d3771ce
move What's New 113 to Archive, like in "main"
mikehoffms Apr 11, 2024
ba4dcb1
Merge branch 'main' into wv2-toc
mikehoffms Apr 17, 2024
4f60074
Merge branch 'main' into wv2-toc
mikehoffms Apr 22, 2024
ac654b1
Merge branch 'main' into wv2-toc
mikehoffms Apr 25, 2024
0f49a9d
Merge branch 'main' into wv2-toc
mikehoffms Apr 30, 2024
67e7d85
Merge branch 'main' into wv2-toc
mikehoffms May 16, 2024
d1a7b4b
Merge branch 'main' into wv2-toc
mikehoffms May 22, 2024
a257117
Merge branch 'main' into wv2-toc
mikehoffms May 23, 2024
6e53a53
Merge branch 'main' into wv2-toc
mikehoffms May 29, 2024
e614712
Merge branch 'main' into wv2-toc
mikehoffms Jul 11, 2024
9798425
Merge branch 'main' into wv2-toc
mikehoffms Jul 19, 2024
eb8b196
Merge branch 'main' into wv2-toc
mikehoffms Jul 25, 2024
94f885b
Merge branch 'main' into wv2-toc
mikehoffms Jul 25, 2024
875a6c1
Merge branch 'main' into wv2-toc
mikehoffms Aug 8, 2024
fc9242b
Merge branch 'main' into wv2-toc
mikehoffms Aug 14, 2024
431fe8f
Merge branch 'main' into wv2-toc
mikehoffms Aug 20, 2024
ecd0f72
Merge branch 'main' into wv2-toc
mikehoffms Aug 26, 2024
1fd3848
Merge branch 'main' into wv2-toc
mikehoffms Sep 3, 2024
df4501c
Merge branch 'main' into wv2-toc
mikehoffms Sep 16, 2024
8bac0cf
Merge branch 'main' into wv2-toc
mikehoffms Sep 20, 2024
549330a
Merge branch 'main' into wv2-toc
mikehoffms Oct 10, 2024
43738e4
Samples before GetStarts
mikehoffms Oct 16, 2024
f070081
Merge branch 'main' into wv2-toc
mikehoffms Oct 16, 2024
20bbb3b
Merge branch 'main' into wv2-toc
mikehoffms Oct 25, 2024
8c279fb
sequence of samples to install/run
mikehoffms Oct 28, 2024
99e945e
adjust/trim list
mikehoffms Oct 28, 2024
f0890c4
can read
mikehoffms Oct 30, 2024
9edbd7b
Merge branch 'main' into wv2-toc
mikehoffms Nov 4, 2024
647deab
Merge branch 'main' into wv2-toc
mikehoffms Nov 7, 2024
5d72723
group sample w/ getstart per plat
mikehoffms Nov 7, 2024
e357d7c
plats bucket
mikehoffms Nov 7, 2024
85dd82e
Platforms
mikehoffms Nov 7, 2024
09b2c9f
Platforms and samples
mikehoffms Nov 7, 2024
cedd5f2
demote roadmap
mikehoffms Nov 13, 2024
241be23
group nav, events, auth
mikehoffms Nov 13, 2024
d68781b
fix dbl-nested Debug
mikehoffms Nov 13, 2024
dcf0ce7
process/threading model
mikehoffms Nov 13, 2024
31fecef
cmts to del debug.md in new PR
mikehoffms Nov 13, 2024
efb6b73
overviewapis
mikehoffms Nov 13, 2024
e10d541
restore Best practices bucket
mikehoffms Nov 13, 2024
90a8482
2 Test buckets
mikehoffms Nov 13, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion microsoft-edge/developer/index.yml
mikehoffms marked this conversation as resolved.
Show resolved Hide resolved
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Create a separate PR to propose deleting wv2's debug.md.

  • That used to contain single tabset containing 3 separate articles, which became 3 .md's.
  • No article links to here.

Propagate parts of its lead-in to top of the 3 child articles.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Create a separate PR to propose deleting Roadmap.md

Copy link
Contributor Author

@mikehoffms mikehoffms Nov 13, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i'll make sure no article was dropped (a periodic check):
walk through live rendered TOC, find article in PR's rendered TOC

Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ landingContent:
url: ../webview2/get-started/get-started.md
- linkListType: download
links:
- text: Sample Code
- text: WebView2 sample apps
url: ../webview2/code-samples-links.md
- linkListType: whats-new
links:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,7 @@ Adds an **Autofill** tool to DevTools, to record various events that the browser

See also:
* [Autofill](/legal/microsoft-edge/privacy#autofill) in _Microsoft Edge Privacy Whitepaper_.
* [Autofill](../../webview2/concepts/overview-features-apis.md?tabs=dotnetcsharp#autofill) in _Overview of WebView2 features and APIs_.
* [Autofill](../../webview2/concepts/overview-features-apis.md?tabs=dotnetcsharp#autofill) in _Overview of WebView2 APIs_.

Status:
* This checkbox is present in Microsoft Edge Canary 131.
Expand Down
2 changes: 1 addition & 1 deletion microsoft-edge/devtools-protocol-chromium/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -277,5 +277,5 @@ JSON object which represents the available API surface for the version of the pr
## See also

* [Chrome DevTools Protocol](https://chromedevtools.github.io/devtools-protocol/)
* [Chrome DevTools Protocol (CDP)](../webview2/concepts/overview-features-apis.md#chrome-devtools-protocol-cdp) in _Overview of WebView2 features and APIs_
* [Chrome DevTools Protocol (CDP)](../webview2/concepts/overview-features-apis.md#chrome-devtools-protocol-cdp) in _Overview of WebView2 APIs_
* [Use the Chrome DevTools Protocol (CDP) in WebView2 apps](../webview2/how-to/chromium-devtools-protocol.md)
2 changes: 1 addition & 1 deletion microsoft-edge/index.yml
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ conceptualContent:
url: ./webview2/get-started/get-started.md
itemType: get-started

- text: Sample Code
- text: WebView2 sample apps
url: ./webview2/code-samples-links.md
itemType: download

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@ To learn more, see [Re-engage users with push messages](push.md).

Using Microsoft Edge DevTools, you can see if your service worker has been registered correctly, and see which lifecycle state the service worker is currently in. Also, you can debug the JavaScript code in your service worker.

To learn more, see [Debug your service worker](debug.md#debug-your-service-worker).
To learn more, see [Debug your service worker](./debug.md#debug-your-service-worker) in _Debug Progressive Web Apps_.


<!-- ====================================================================== -->
Expand Down
2 changes: 1 addition & 1 deletion microsoft-edge/puppeteer/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ The preceding example demonstrates basic automation and testing scenarios that y

* [WebDriver](../webdriver-chromium/index.md)
* [Contact the Microsoft Edge DevTools team](../devtools-guide-chromium/contact.md) to send feedback about using Puppeteer, puppeteer-core, and Microsoft Edge.
* [Chrome DevTools Protocol (CDP)](../webview2/concepts/overview-features-apis.md#chrome-devtools-protocol-cdp) in _Overview of WebView2 features and APIs_
* [Chrome DevTools Protocol (CDP)](../webview2/concepts/overview-features-apis.md#chrome-devtools-protocol-cdp) in _Overview of WebView2 APIs_
* [Use the Chrome DevTools Protocol (CDP) in WebView2 apps](../webview2/how-to/chromium-devtools-protocol.md)

#### Archive
Expand Down
434 changes: 216 additions & 218 deletions microsoft-edge/toc.yml

Large diffs are not rendered by default.

5 changes: 3 additions & 2 deletions microsoft-edge/webview2/code-samples-links.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Sample apps
title: WebView2 sample apps
description: Sample apps for WebView2, for various frameworks or platforms including WinUI 2 (UWP), WinUI 3 (Windows App SDK), WPF, WPF with Chrome DevTools Protocol extension, WinForms, Win32/C++, and Win32 with Visual Composition.
author: MSEdgeTeam
ms.author: msedgedevrel
Expand All @@ -8,7 +8,7 @@ ms.service: microsoft-edge
ms.subservice: webview
ms.date: 08/29/2022
---
# Sample apps
# WebView2 sample apps


<!-- ====================================================================== -->
Expand Down Expand Up @@ -49,3 +49,4 @@ For some frameworks or platforms, the samples repo contains both a completed Get
## See also

* [WebView2Samples repo](https://github.com/MicrosoftEdge/WebView2Samples#readme)
* [WebView2 deployment samples](./samples/deployment-samples.md)
6 changes: 3 additions & 3 deletions microsoft-edge/webview2/concepts/data-privacy.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ If you don't disable SmartScreen, you must provide notice to all users that your
---

See also:
* [SmartScreen](../concepts/overview-features-apis.md#smartscreen) in _Overview of WebView2 features and APIs_.
* [SmartScreen](../concepts/overview-features-apis.md#smartscreen) in _Overview of WebView2 APIs_.
* [Spec: Disable SmartScreen](https://github.com/MicrosoftEdge/WebView2Feedback/blob/main/specs/IsSmartScreenRequired.md)


Expand Down Expand Up @@ -111,12 +111,12 @@ If any WebView2 process crashes, one or more minidump files are created and sent
---

See also:
* [Custom crash reporting](../concepts/overview-features-apis.md#custom-crash-reporting) in _Overview of WebView2 features and APIs_.
* [Custom crash reporting](../concepts/overview-features-apis.md#custom-crash-reporting) in _Overview of WebView2 APIs_.
* [Spec: Custom Crash Reports](https://github.com/MicrosoftEdge/WebView2Feedback/blob/main/specs/DisableCrashReporting.md)
* [Minidump Files](/windows/win32/debug/minidump-files)


<!-- ====================================================================== -->
## See also

* [Security and privacy](../concepts/overview-features-apis.md#security-and-privacy) in _Overview of WebView2 features and APIs_.
* [Security and privacy](../concepts/overview-features-apis.md#security-and-privacy) in _Overview of WebView2 APIs_.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ ms.date: 06/24/2022
# Main classes for WebView2: Environment, Controller, and Core

<!-- keep sync'd:
* [Main classes: Environment, Controller, and Core](overview-features-apis.md#main-classes-environment-controller-and-core) in _Overview of WebView2 features and APIs_.
* [Main classes: Environment, Controller, and Core](overview-features-apis.md#main-classes-environment-controller-and-core) in _Overview of WebView2 APIs_.
* [Main classes for WebView2: Environment, Controller, and Core](environment-controller-core.md) - topmost content.
-->

Expand Down
20 changes: 10 additions & 10 deletions microsoft-edge/webview2/concepts/frames.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ WebView2 supports APIs to interact with iframes. You can:
* Allow the app to ignore the `X-Frame-Options` HTTP response header.

See also:
* [iframes](./overview-features-apis.md#iframes) in _Overview of WebView2 features and APIs_.
* [iframes](./overview-features-apis.md#iframes) in _Overview of WebView2 APIs_.
* [HTML <iframe\> Tag](https://www.w3schools.com/tags/tag_iframe.asp)<!-- keep escape -->


Expand Down Expand Up @@ -56,7 +56,7 @@ Your host app must monitor the lifetime of a frame by subscribing to the `CoreWe
---

See also:
* [iframes](./overview-features-apis.md#iframes) in _Overview of WebView2 features and APIs_.
* [iframes](./overview-features-apis.md#iframes) in _Overview of WebView2 APIs_.


<!-- ====================================================================== -->
Expand Down Expand Up @@ -137,8 +137,8 @@ Regarding the duplicated equivalent `NavigationStarting` and `NavigationComplete

See also:
* [Standard sequence of events](./navigation-events.md) in _Navigation events for WebView2 apps_.
* [Navigation events](./overview-features-apis.md#navigation-events) in _Overview of WebView2 features and APIs_.
* [Block unwanted navigating](./overview-features-apis.md#block-unwanted-navigating) in _Overview of WebView2 features and APIs_.
* [Navigation events](./overview-features-apis.md#navigation-events) in _Overview of WebView2 APIs_.
* [Block unwanted navigating](./overview-features-apis.md#block-unwanted-navigating) in _Overview of WebView2 APIs_.


<!-- ====================================================================== -->
Expand Down Expand Up @@ -194,7 +194,7 @@ See [Step 6: Call AddHostObjectToScript to pass the host object to web-side code


See also:
* [Host/web object sharing](./overview-features-apis.md#hostweb-object-sharing) in _Overview of WebView2 features and APIs_.
* [Host/web object sharing](./overview-features-apis.md#hostweb-object-sharing) in _Overview of WebView2 APIs_.


<!-- ====================================================================== -->
Expand Down Expand Up @@ -250,7 +250,7 @@ window.chrome.webview.addEventListener('message', arg => {

See also:
* [Interop of native-side and web-side code](/microsoft-edge/webview2/how-to/communicate-btwn-web-native)
* [Web messaging](./overview-features-apis.md#web-messaging) in _Overview of WebView2 features and APIs_.
* [Web messaging](./overview-features-apis.md#web-messaging) in _Overview of WebView2 APIs_.


<!--
Expand Down Expand Up @@ -289,7 +289,7 @@ For information about the `ContentLoading` event, see [Navigation events for Web
---

See also:
* [Script execution](./overview-features-apis.md#script-execution) in _Overview of WebView2 features and APIs_.
* [Script execution](./overview-features-apis.md#script-execution) in _Overview of WebView2 APIs_.


<!-- ====================================================================== -->
Expand All @@ -300,7 +300,7 @@ See also:
For iframes, you can listen to network events and modify them, by using the `WebResourceRequested` event.

See also:
* [Manage network requests in WebView2](./overview-features-apis.md#manage-network-requests-in-webview2) in _Overview of WebView2 features and APIs_.
* [Manage network requests in WebView2](./overview-features-apis.md#manage-network-requests-in-webview2) in _Overview of WebView2 APIs_.
* [Custom management of network requests](../how-to/webresourcerequested.md)
* [Experimental APIs for 1.0.1222-prerelease](../release-notes/archive.md#experimental-apis-for-101222-prerelease) in _Archived Release Notes for the WebView2 SDK_.

Expand Down Expand Up @@ -477,7 +477,7 @@ if (webview2_4)
<!-- ====================================================================== -->
## API Reference overview

The following features, listed in [Overview of WebView2 features and APIs](./overview-features-apis.md), include frame-related APIs:
The following features, listed in [Overview of WebView2 APIs](./overview-features-apis.md), include frame-related APIs:

* [Host/web object sharing](./overview-features-apis.md#hostweb-object-sharing)
* [iframes](./overview-features-apis.md#iframes)<!--same link is in h2 "Subscribing to the FrameCreated event" above-->
Expand All @@ -491,7 +491,7 @@ The following features, listed in [Overview of WebView2 features and APIs](./ove
<!-- ====================================================================== -->
## See also

* [Call native-side code from web-side code](../how-to/hostobject.md)
* [Interop of native and web code](../how-to/hostobject.md)
* [Navigation events for WebView2 apps](./navigation-events.md) - valid for frames as well as webpages.

**External pages:**
Expand Down
2 changes: 1 addition & 1 deletion microsoft-edge/webview2/concepts/multi-profile-support.md
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ HRESULT AppWindow::OnCreateCoreWebView2ControllerCompleted(HRESULT result, ICore
<!-- ====================================================================== -->
## See also

* [Multiple profiles](./overview-features-apis.md#multiple-profiles) in _Overview of WebView2 features and APIs_.
* [Multiple profiles](./overview-features-apis.md#multiple-profiles) in _Overview of WebView2 APIs_.
* [Manage the user data folder](user-data-folder.md)
* [Clear browsing data from the user data folder](clear-browsing-data.md)
* [Spec for multiple profile support API](https://github.com/MicrosoftEdge/WebView2Feedback/blob/main/specs/MultiProfile.md)
4 changes: 2 additions & 2 deletions microsoft-edge/webview2/concepts/navigation-events.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,13 +84,13 @@ For example code showing how to handle navigation events, see:
* [Step 8 - Navigation events](../get-started/winforms.md#step-8---navigation-events) in _Get started with WebView2 in WinForms apps_.
* [Step 13 - Navigation events](../get-started/win32.md#step-13---navigation-events) in _Get started with WebView2 in Win32 apps_.

The WebView2 [Sample apps](../code-samples-links.md) also demonstrate handling navigation events.
The [WebView2 sample apps](../code-samples-links.md) also demonstrate handling navigation events.


<!-- ====================================================================== -->
## See also

* [Navigate to pages and manage loaded content](./overview-features-apis.md#navigate-to-pages-and-manage-loaded-content) in _Overview of WebView2 features and APIs_
* [Navigate to pages and manage loaded content](./overview-features-apis.md#navigate-to-pages-and-manage-loaded-content) in _Overview of WebView2 APIs_
* [Basic authentication for WebView2 apps](./basic-authentication.md)
* [Get started with WebView2](../get-started/get-started.md)
* [WebView2Samples repo](https://github.com/MicrosoftEdge/WebView2Samples) - a comprehensive example of WebView2 capabilities.
Expand Down
12 changes: 6 additions & 6 deletions microsoft-edge/webview2/concepts/overview-features-apis.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
---
title: Overview of WebView2 features and APIs
description: Overview of WebView2 features and APIs.
title: Overview of WebView2 APIs
description: Overview of WebView2 APIs.
author: MSEdgeTeam
ms.author: msedgedevrel
ms.topic: conceptual
ms.service: microsoft-edge
ms.subservice: webview
ms.date: 10/21/2024
---
# Overview of WebView2 features and APIs
# Overview of WebView2 APIs

Embedding the WebView2 control in your app gives your app access to various methods and properties that are provided through the WebView2 classes or interfaces. WebView2 has hundreds of APIs that provide a vast set of capabilities, ranging from enhancing your app's native-platform capabilities, to enabling your app to modify browser experiences. This article provides a high-level grouping of the WebView2 APIs to help you understand the different things you can do using WebView2.

Expand Down Expand Up @@ -47,7 +47,7 @@ This page only lists APIs that are in Release SDKs; it doesn't list Experimental
## Main classes: Environment, Controller, and Core

<!-- keep sync'd:
* [Main classes: Environment, Controller, and Core](overview-features-apis.md#main-classes-environment-controller-and-core) in _Overview of WebView2 features and APIs_.
* [Main classes: Environment, Controller, and Core](overview-features-apis.md#main-classes-environment-controller-and-core) in _Overview of WebView2 APIs_.
* [Main classes for WebView2: Environment, Controller, and Core](environment-controller-core.md) - topmost content.
-->

Expand Down Expand Up @@ -101,7 +101,7 @@ Common use cases for web/native interop:
* Run a dedicated JavaScript file on the web side of an application.

See also:
* [Interop of native-side and web-side code](../how-to/communicate-btwn-web-native.md)
* [Interop of native and web code](../how-to/communicate-btwn-web-native.md)
* [Call web-side code from native-side code](../how-to/javascript.md)
* [Call native-side code from web-side code](../how-to/hostobject.md)
* [Call native-side WinRT code from web-side code](../how-to/winrt-from-js.md)
Expand Down Expand Up @@ -1970,7 +1970,7 @@ These APIs load, stop loading, and reload content to WebView2. The content that
* Content from a constructed network request.

See also:
* [Working with local content in WebView2 apps](./working-with-local-content.md)
* [Use local content in WebView2 apps](./working-with-local-content.md)

##### [.NET/C#](#tab/dotnetcsharp)

Expand Down
10 changes: 5 additions & 5 deletions microsoft-edge/webview2/concepts/process-related-events.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Handling process-related events in WebView2
title: Handle process-related events in WebView2
description: Process-related events in WebView2 and how apps can handle them for recovery and improved reliability.
author: MSEdgeTeam
ms.author: msedgedevrel
Expand All @@ -8,16 +8,16 @@ ms.service: microsoft-edge
ms.subservice: webview
ms.date: 07/13/2023
---
# Handling process-related events in WebView2
# Handle process-related events in WebView2

WebView2 uses multiple processes to support the WebView2 controls in your application. Because these processes can exit during use, WebView2 provides the `CoreWebView2.ProcessFailed` and `CoreWebView2Environment.BrowserProcessExited` events for your application to react to different scenarios. Use this document to learn how to use these events to react when these scenarios occur.
WebView2 uses multiple processes to support the WebView2 controls in your application. Because these processes can exit during use, WebView2 provides the `CoreWebView2.ProcessFailed` and `CoreWebView2Environment.BrowserProcessExited` events. Have your app use these events as follows, to react when these scenarios occur.

To improve the reliability of your WebView2 application, it is recommended that your app handles at least the following events:
* [The main browser process has exited unexpectedly](#the-main-browser-process-has-exited-unexpectedly).
* [A process rendering content in the WebView2 control has exited unexpectedly](#a-process-rendering-content-in-the-webview2-control-has-exited-unexpectedly).
* [A renderer process becomes unresponsive](#handle-unresponsive-renderers).

To use this article, we recommend first reading [Process model for WebView2 apps](./process-model.md). For a list of process-related APIs covered by this article, see [Process management](overview-features-apis.md#process-management) in _Overview of WebView2 features and APIs_.
To use this article, we recommend first reading [Process model for WebView2 apps](./process-model.md). For a list of process-related APIs covered by this article, see [Process management](overview-features-apis.md#process-management) in _Overview of WebView2 APIs_.


<!-- ------------------------------
Expand Down Expand Up @@ -324,5 +324,5 @@ To ensure that a new main browser process instance is used when re-creating the
## See also

* [Process model for WebView2 apps](./process-model.md)
* [Process management](overview-features-apis.md#process-management) in _Overview of WebView2 features and APIs_.
* [Process management](overview-features-apis.md#process-management) in _Overview of WebView2 APIs_.
* [WebView2 API Reference](../webview2-api-reference.md)
Loading