Skip to content

Commit 1682c39

Browse files
committed
del unused png
1 parent eb1e6fe commit 1682c39

3 files changed

Lines changed: 44 additions & 50 deletions

File tree

-62 KB
Binary file not shown.

microsoft-edge/devtools-guide-chromium/quick-source/quick-source-tool.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -123,11 +123,11 @@ For example, if not done already, clone the **MicrosoftEdge / Demos** repo to yo
123123
```
124124

125125
For details about cloning a repo, see:
126-
* [Clone the Demos repo](../sample-code/sample-code.md#clone-the-demos-repo) in _Sample code for DevTools_.<!-- todo: show git bash, not only VS Code's Source Control pane -->
126+
* [Clone the Edge Demos repo to your drive](../sample-code/sample-code.md#clone-the-edge-demos-repo-to-your-drive) in _Sample code for DevTools_.<!-- todo: show git bash, not only VS Code's Source Control pane -->
127127
* [Clone the WebView2Samples repo](../../webview2/how-to/machine-setup.md#clone-the-webview2samples-repo) in _Set up your Dev environment for WebView2_. Shows a different sample repo, but shows steps for several tools.
128128
* [Cloning a repository](https://docs.github.com/en/repositories/creating-and-managing-repositories/cloning-a-repository) - GitHub docs.
129129

130-
Now you have a local folder of source files (such as `/demo-to-do/`) that match the files on the web server.
130+
Now you have a local folder of source files (such as `/demo-to-do/`) that match the files on the web server.
131131

132132
Continue with the next section.
133133

@@ -183,7 +183,7 @@ Continue with the next section.
183183
Now, when you edit the folder's files in DevTools, the edits are not only made to the transient file that's returned by the server, but are also saved to the source files on your local drive. You can edit the file from within the **Quick source** tool at the same time as displaying another tool (or from within the **Sources** tool).
184184

185185
See also:
186-
* [Select a local Workspace, to use DevTools to edit files and save changes to disk](../sources/index.md#select-a-local-workspace-to-use-devtools-to-edit-files-and-save-changes-to-disk) in _Sources tool overview_.
186+
* [Add a local folder to the workspace, to use DevTools to edit files and save changes to disk](../sources/index.md#add-a-local-folder-to-the-workspace-to-use-devtools-to-edit-files-and-save-changes-to-disk) in _Sources tool overview_.
187187
* [Edit and save files in a workspace](../workspaces/index.md)
188188
* [Step 4: Save a JavaScript change to disk](../workspaces/index.md#step-4-save-a-javascript-change-to-disk) in _Edit and save files in a workspace_
189189

microsoft-edge/devtools-guide-chromium/sample-code/sample-code.md

Lines changed: 41 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ Cloning a repo enables updating your local copy when the repo is updated. Many
176176

177177

178178
<!-- ====================================================================== -->
179-
## Clone the Edge Demos repo to your drive by using git commands
179+
## Clone the Edge Demos repo to your drive
180180

181181
The **Microsoft Edge / Demos** repo is useful for following the various DevTools documentation. You can clone the repo, start a localhost web server within a folder of the cloned repo, and then edit the demo files directly within DevTools, or within an editor such as VS Code.
182182

@@ -208,8 +208,8 @@ For details about cloning a repo, see:
208208
Continue with the next section.
209209

210210

211-
<!-- ====================================================================== -->
212-
## Clone the Edge Demos repo to your drive by using VS Code
211+
<!-- ------------------------------ -->
212+
#### Clone the Edge Demos repo to your drive by using VS Code
213213

214214
To clone the **MicrosoftEdge / Demos** repo to your local drive:
215215

@@ -264,21 +264,16 @@ See also:
264264

265265

266266
<!-- ====================================================================== -->
267-
## Open a demo folder in the Sources tool and edit a file
268-
269-
To use this section, first [Clone the Edge Demos repo to your drive by using git commands](#clone-the-edge-demos-repo-to-your-drive-by-using-git-commands), or clone the repo another way, or download the repo.
267+
## Open a demo folder from the Workspace tab in the Sources tool
268+
<!-- todo: flatten article's TOC, then demote a few headings -->
270269

271-
To edit local files in the **Sources** tool, you might need to first click the **Allow** button to grant read/write access. To do that, follow the steps in [Opening a folder from the Workspace tab in the Sources tool](#opening-a-folder-from-the-workspace-tab-in-the-sources-tool) below.
270+
To use this section, first do [Clone the Edge Demos repo to your drive](#clone-the-edge-demos-repo-to-your-drive), above.
272271

273272
See also:
274273
* [Approaches compared](../../visual-studio-code/microsoft-edge-devtools-extension.md#approaches-compared) in _Microsoft Edge DevTools extension for Visual Studio Code_. Summarizes and compares several options for editing webpage files.
275274

276275

277-
<!-- ====================================================================== -->
278-
## Open a folder from the Workspace tab in the Sources tool
279-
<!-- todo: flatten article's TOC, then demote a few headings -->
280-
281-
After downloading or cloning the Demos repo:
276+
After cloning (or downloading) the Edge Demos repo:
282277

283278
1. In Microsoft Edge, open a new tab.
284279

@@ -300,48 +295,68 @@ After downloading or cloning the Demos repo:
300295

301296

302297
<!-- ====================================================================== -->
303-
## Starting the localhost server from the Demos directory
298+
## Start the localhost server
304299

305-
If you start the localhost server from within the entire `\Demos\` folder and then go to `localhost:8080`, you can navigate to each demo from within the browser. You can add the entire cloned `/Demos/` folder to the **Workspace** tab of the **Sources** tool. You then have full functionality for using DevTools as an IDE.
300+
If you start the localhost server from a specific demo folder, such as `\Demos\demo-to-do`, and then go to `localhost:8080` (or simply open the local file such as `C:\Users\localAccount\GitHub\Demos\demo-to-do\index.html` in Microsoft Edge), the specific demo immediately is displayed in the browser. You can then add just the specific demo directory, such as `C:\Users\localAccount\GitHub\Demos\demo-to-do\`, to the **Workspace** tab of the **Sources** tool. You then have full functionality for using DevTools as an IDE, for that specific demo.
306301

307-
Starting the server from within the entire `\Demos\` directory:
302+
Starting the server from within a specific demo directory:
308303

309304
```
310-
$ cd "C:\Users\localAccount\GitHub\Demos"
305+
$ cd "C:\Users\localAccount\GitHub\Demos\demo-to-do"
311306
$ npx http-server
312307
```
313308

314-
Example directory to add to the **Workspace** tab of the **Sources** tool: `C:\Users\localAccount\GitHub\Demos`
309+
Example directory to add to the **Workspace** tab of the **Sources** tool: `C:\Users\localAccount\GitHub\Demos\demo-to-do`
315310

316311
Result of going to `localhost:8080`:
317312

318-
![Server started from /demos/ directory instead of a specific demo subdirectory](./sample-code-images/server-started-from-demos-dir.png)
313+
![Server started from the \Demos\demo-to-do directory](./sample-code-images/server-started-from-a-demo-dir.png)
319314

320315

321-
<!-- ====================================================================== -->
322-
## Starting the localhost server from a specific Demos subdirectory
316+
<!-- ------------------------------ -->
317+
#### Starting the localhost server from the Demos directory
323318

324-
If you start the localhost server from a specific demo folder, such as `\Demos\demo-to-do`, and then go to `localhost:8080` (or simply open the local file such as `C:\Users\localAccount\GitHub\Demos\demo-to-do\index.html` in Microsoft Edge), the specific demo immediately is displayed in the browser. You can then add just the specific demo directory, such as `C:\Users\localAccount\GitHub\Demos\demo-to-do\`, to the **Workspace** tab of the **Sources** tool. You then have full functionality for using DevTools as an IDE, for that specific demo.
319+
If you start the localhost server from within the entire `\Demos\` folder and then go to `localhost:8080`, you can navigate to each demo from within the browser. You can add the entire cloned `/Demos/` folder to the **Workspace** tab of the **Sources** tool. You then have full functionality for using DevTools as an IDE.
325320

326-
Starting the server from within a specific demo directory:
321+
Starting the server from within the entire `\Demos\` directory:
327322

328323
```
329-
$ cd "C:\Users\localAccount\GitHub\Demos\demo-to-do"
324+
$ cd "C:\Users\localAccount\GitHub\Demos"
330325
$ npx http-server
331326
```
332327

333-
Example directory to add to the **Workspace** tab of the **Sources** tool: `C:\Users\localAccount\GitHub\Demos\demo-to-do`
328+
Example directory to add to the **Workspace** tab of the **Sources** tool: `C:\Users\localAccount\GitHub\Demos`
334329

335330
Result of going to `localhost:8080`:
336331

337-
![Server started from the \Demos\demo-to-do directory](./sample-code-images/server-started-from-a-demo-dir.png)
332+
![Server started from /demos/ directory instead of a specific demo subdirectory](./sample-code-images/server-started-from-demos-dir.png)
338333

339334

340335
<!-- ====================================================================== -->
341-
## Opening a local HTML file from browser's File Open dialog and editing it in DevTools
336+
## Opening a local HTML file from File Explorer and editing it in DevTools
342337

343338
To edit files in the **Sources** tool, before doing the steps in this section, you might need to click the **Allow** button to grant read/write access by following the steps in [Opening a folder from the Workspace tab in the Sources tool](#opening-a-folder-from-the-workspace-tab-in-the-sources-tool) above.
344339

340+
1. In File Explorer on Windows, or Finder on macOS, select an HTML file from the local copy of the **Demos** repo, such as `C:\Users\localAccount\Documents\GitHub\Demos\demo-to-do\index.html`.
341+
342+
The `.html` file is opened and rendered in Microsoft Edge.
343+
344+
The Address bar displays: **File | C:/Users/localAccount/GitHub/Demos/demo-to-do/index.html**
345+
346+
Selecting the URL in the address bar shows the URL format: `file:///C:/Users/localAccount/GitHub/Demos/demo-to-do/index.html`
347+
348+
1. Right-click the rendered webpage, and then select **Inspect**.
349+
350+
DevTools opens.
351+
352+
1. Select the **Sources** tool, and then select the **Page** tab or the **Workspace** tab.
353+
354+
See also:
355+
* [Edit and save files in a workspace](../workspaces/index.md) - to open a local folder in the **Sources** tool of DevTools in the browser.
356+
357+
358+
<!-- ------------------------------ -->
359+
#### Opening a local HTML file from the browser's File Open dialog and editing it in DevTools
345360

346361
To open an `.html` file and edit it:
347362

@@ -378,27 +393,6 @@ To open an `.html` file and edit it:
378393
![The modified demo-to-do page after saving changes and refreshing](./sample-code-images/modified-demo-to-do-after-save-refresh.png)
379394

380395

381-
<!-- ====================================================================== -->
382-
## Opening a local HTML file from File Explorer and editing it in the browser
383-
384-
1. In File Explorer on Windows, or Finder on macOS, select an HTML file from the local copy of the **Demos** repo, such as `C:\Users\localAccount\Documents\GitHub\Demos\demo-to-do\index.html`.
385-
386-
The `.html` file is opened and rendered in Microsoft Edge.
387-
388-
The Address bar displays: **File | C:/Users/localAccount/GitHub/Demos/demo-to-do/index.html**
389-
390-
Selecting the URL in the address bar shows the URL format: `file:///C:/Users/localAccount/GitHub/Demos/demo-to-do/index.html`
391-
392-
1. Right-click the rendered webpage, and then select **Inspect**.
393-
394-
DevTools opens.
395-
396-
1. Select the **Sources** tool, and then select the **Page** tab or the **Workspace** tab.
397-
398-
See also:
399-
* [Edit and save files in a workspace](../workspaces/index.md) - to open a local folder in the **Sources** tool of DevTools in the browser.
400-
401-
402396
<!-- ====================================================================== -->
403397
## Open a demo folder in Visual Studio Code
404398

0 commit comments

Comments
 (0)