NavigatorUAData.toJSON()

The toJSON() method of the NavigatorUAData interface is a serializer that returns a JSON representation of the low entropy properties of the NavigatorUAData object.

Note: The terms high entropy and low entropy refer to the amount of information these values reveal about the browser. The low entropy values returned by this method are those which do not reveal information able to identify a user. High entropy values can only be returned by the NavigatorUAData.getHighEntropyValues() method.

Syntax

NavigatorUAData.toJSON();

Parameters

None.

Return value

A JSON object.

Examples

The following example prints the JSON object to the console.

console.log(navigator.userAgentData.toJSON());

Specifications

No specification found

No specification data found for api.NavigatorUAData.toJSON.
Check for problems with this page or contribute a missing spec_url to mdn/browser-compat-data. Also make sure the specification is included in w3c/browser-specs.

Browser compatibility

No compatibility data found for api.NavigatorUAData.toJSON.
Check for problems with this page or contribute missing data to mdn/browser-compat-data.