Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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: 2 additions & 0 deletions files/en-us/web/api/performanceresourcetiming/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ The interface also supports the following properties which are listed in the ord
- : A `number` that is the size (in octets) received from the fetch (HTTP or cache) of the _message body_, after removing any applied content-codings.
- {{domxref('PerformanceResourceTiming.serverTiming')}} {{ReadOnlyInline}}
- : An array of {{domxref("PerformanceServerTiming")}} entries containing server timing metrics.
- {{domxref('PerformanceResourceTiming.renderBlockingStatus')}} {{ReadOnlyInline}}
- : A string representing the render-blocking status. Must be: "`blocking`" or "`non-blocking`".

## Instance methods

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
---
title: PerformanceResourceTiming.renderBlockingStatus
slug: Web/API/PerformanceResourceTiming/renderBlockingStatus
page-type: web-api-instance-property
tags:
- API
- Property
- Reference
- Web Performance
browser-compat: api.PerformanceResourceTiming.renderBlockingStatus
---

{{APIRef("Resource Timing API")}}

Render-blocking resources are static files, such as fonts, CSS, and JavaScript that block or delay the browser from rendering page content to the screen.
The **`renderBlockingStatus`** read-only property returns the render-blocking nature of the resource.
This eliminates the need to rely on complex heuristics to identify render-blocking resources.

## Value

A string containing one of the following values:

- `"blocking"`
- : The resource might potentially block rendering.
- `"non-blocking"`
- : The resource does not block rendering.

## Examples

In the following example, we print out the {{domxref("PerformanceEntry.name","name")}} of resources which are potentially render-blocking.

```js
function printRenderBlockingResources() {
const entries = performance.getEntriesByType("resource");
for (const entry of entries) {
if (entry.renderBlockingStatus === "blocking") {
console.log(entry.name);
}
}
}

printRenderBlockingResources();
```

## Specifications

{{Specifications}}

## Browser compatibility

{{Compat}}