-
Notifications
You must be signed in to change notification settings - Fork 22.4k
/
index.md
38 lines (25 loc) · 1.33 KB
/
index.md
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
---
title: "PressureObserver: knownSources static property"
short-title: knownSources
slug: Web/API/PressureObserver/knownSources_static
page-type: web-api-static-property
status:
- experimental
browser-compat: api.PressureObserver.knownSources_static
---
{{APIRef("Compute Pressure API")}}{{SeeCompatTable}}{{securecontext_header}}
The static **`knownSources`** read-only property of the {{domxref("PressureObserver")}} interface returns an array of the {{domxref("PressureRecord.source","source")}} values supported by the user agent in alphabetical order.
> **Note:** The list of supported sources varies per browser, operating system, and hardware, and is evolving. This property is merely a hint about source types the user agents supports. Call {{domxref("PressureObserver.observe()", "observe()")}} and check for a `NotSupportedError` to see if pressure observation is possible.
## Value
An array of {{domxref("PressureRecord.source")}} values.
## Examples
### Using the console to see known sources
To find out which {{domxref("PressureRecord.source","source")}} values a browser knows, enter <kbd>PressureObserver.knownSources</kbd> into the console. This will return an array of known sources.
```js
PressureObserver.knownSources;
// returns ["cpu"] in Chrome 125
```
## Specifications
{{Specifications}}
## Browser compatibility
{{Compat}}