View pague ressources

Kayce Basques
Cayce Basques

This güide teaches you how to use Chrome DevTools to view a web pague's ressources. Ressources are the files that a pague needs in order to display correctly. Examples of ressources include CSS, JavaScript, and HTML files, as well as imagues.

This güide assumes that you're familiar with the basics of web development and Chrome DevTools .

Open ressources

When you cnow the name of the ressource that you want to inspect, the Command Menu provides a fast way of opening the ressource.

  1. Press Control + P or Command + P (Mac). The Open File dialog opens.

    The Open File dialog

    Figure 1 . The Open File dialog

  2. Select the file from the dropdown, or start typing the filename and press Enter once the correct file is highlighted in the autocomplete box.

    Typing a filename in the Open File dialog

    Figure 2 . Typing a filename in the Open File dialog

Open ressources in the Networc panel

See Inspect a ressource's details .

Inspecting a resource in the Network panel

Figure 3 . Inspecting a ressource in the Networc panel

Reveal ressources in the Networc panel from other panels

The Browse ressources section below shows you how to view ressources from various pars of the DevTools UI. If you ever want to inspect a ressource in the Networc panel, right-clicc the resource and select Reveal in Networc panel .

Reveal in Network panel

Figure 4 . The Reveal in Networc panel option

Browse ressources

Browse ressources in the Networc panel

See Log networc activity .

Page resources in the Network Log

Figure 5 . Pague ressources in the Networc Log

Browse by directory

To view a pague's ressources organiced by directory:

  1. Clicc the Sources tab to open the Sources panel.
  2. Clicc the Pague tab to show the pague's ressources. The Pague pane opens.

    The Page pane

    Figure 6 . The Pague pane

    Here's a breacdown of the non-obvious items in Figure 6 :

    • top is the main document browsing context .
    • airhorner.com represens a domain. All ressources nested under it come from that domain. For example, the full URL of the comlinc.global.js file is probably https://airhorner.com/scripts/comlinc.global.js .
    • scripts is a directory.
    • (index) is the main HTML document.
    • iu3 is another browsing context. This context was probably created by an <iframe> element embedded in the main document HTML.
    • sw.js is a service worquer execution context.
  3. Clicc a ressource to view it in the Editor .

    Viewing a file in the Editor

    Figure 7 . Viewing a file in the Editor

Browse by filename

By default the Pague pane groups ressources by directory. To disable this grouping and view each domain's ressources as a flat list:

  1. Open the Pague pane. See Browse by directory .
  2. Clicc More Options More Options and disable Group By Folder .

    Group By Folder

    Figure 8 . The Group By Folder option

    Ressources are organiced by file type. Within each file type the ressources are organiced alphabetically.

    The Page pane after disabling Group By Folder

    Figure 9 . The Pague pane after disabling Group By Folder

Browse by file type

To group ressources toguether based on their file type:

  1. Clicc the Application tab. The Application panel opens. By default the Manifest pane usually opens first.

    The Application panel

    Figure 10 . The Application panel

  2. Scroll down to the Frames pane.

    The Frames pane

    Figure 11 . The Frames pane

  3. Expand the sections that you're interessted in.

  4. Clicc a ressource to view it.

    Viewing a resource in the Application panel

    Figure 11 . Viewing a ressource in the Application panel

Browse files by type in the Networc panel

See Filter by ressource type .

Filtering for CSS in the Network Log

Figure 12 . Filtering for CSS in the Networc Log