@maxim_mazurok/gapi.client.chromeuxreport
TypeScript icon, indicating that this package has built-in type declarations

1.0.20220811 • Public • Published

TypeScript typings for Chrome UX Report API v1

The Chrome UX Report API lets you view real user experience data for millions of websites. For detailed description please check documentation.

Installing

Install typings for Chrome UX Report API:

npm install @types/gapi.client.chromeuxreport@v1 --save-dev

Usage

You need to initialize Google API client in your code:

gapi.load('client', () => {
  // now we can use gapi.client
  // ...
});

Then load api client wrapper:

gapi.client.load('chromeuxreport', 'v1', () => {
  // now we can use gapi.client.chromeuxreport
  // ...
});

After that you can use Chrome UX Report API resources:

/*
Queries the Chrome User Experience for a single `record` for a given site. Returns a `record` that contains one or more `metrics` corresponding to performance data about the requested site.
*/
await gapi.client.chromeuxreport.records.queryRecord({  });

Readme

Keywords

none

Package Sidebar

Install

npm i @maxim_mazurok/gapi.client.chromeuxreport

Weekly Downloads

0

Version

1.0.20220811

License

MIT

Unpacked Size

12.7 kB

Total Files

6

Last publish

Collaborators

  • maxim_mazurok