Title: Upgrade to web-vitals v3 · Issue #5462 · getsentry/sentry-javascript · GitHub
Open Graph Title: Upgrade to web-vitals v3 · Issue #5462 · getsentry/sentry-javascript
X Title: Upgrade to web-vitals v3 · Issue #5462 · getsentry/sentry-javascript
Description: Problem Statement Web Vitals v3 is currently in beta. Allows us to start tracking INP, which can replace FID. https://web.dev/inp/ Writing your own PerformanceObserver to measure INP can be difficult. To measure INP in JavaScript, it's a...
Open Graph Description: Problem Statement Web Vitals v3 is currently in beta. Allows us to start tracking INP, which can replace FID. https://web.dev/inp/ Writing your own PerformanceObserver to measure INP can be difficu...
X Description: Problem Statement Web Vitals v3 is currently in beta. Allows us to start tracking INP, which can replace FID. https://web.dev/inp/ Writing your own PerformanceObserver to measure INP can be difficu...
Opengraph URL: https://github.com/getsentry/sentry-javascript/issues/5462
X: @github
Domain: github.com
IPv4 address: 140.82.114.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Upgrade to web-vitals v3","articleBody":"### Problem Statement\r\n\r\nWeb Vitals v3 is currently in beta.\r\n\r\nAllows us to start tracking INP, which can replace FID.\r\n\r\nhttps://web.dev/inp/\r\n\r\n> Writing your own [PerformanceObserver](https://developer.mozilla.org/docs/Web/API/PerformanceObserver) to measure INP can be difficult. To measure INP in JavaScript, it's advised that you use the web-vitals JavaScript library, which exports an onINP function to do this work for you. At the moment, getting INP data is only possible in version 3 of web-vitals, currently in beta, which can be installed with the following command:\r\n> ```js\r\n> npm install web-vitals@next --save\r\n> ```\r\n> You can then get a page's INP by passing a function to the onINP method:\r\n> ```js\r\n> import {onINP} from 'web-vitals';\r\n> onINP(({value}) => {\r\n> // Log the value to the console, or send it to your analytics provider.\r\n> console.log(value);\r\n> });\r\n> ```\r\n> As with other methods exported by web-vitals, onINP accepts a function as an argument, and will pass metric data to the function you give it. From there, you can send that data to an endpoint for collection and analysis.\r\n\r\n### Solution Brainstorm\r\n\r\nhttps://www.npmjs.com/package/web-vitals/v/next\r\n\r\nhttps://github.com/GoogleChrome/web-vitals/compare/next\r\n\r\nSeems like its around ~2kb larger. Can we address that?","author":{"url":"https://github.com/AbhiPrasad","@type":"Person","name":"AbhiPrasad"},"datePublished":"2022-07-25T20:52:18Z","url":"https://github.com/getsentry/sentry-javascript/issues/5462"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:65873e0a-2f62-fefe-12bc-cd2556dfbf87 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E9E2:81334:14E160:1D37D0:6B046FBD |
| html-safe-nonce | d2b055dfca1ae5d0ed82c16852c9ba55308b8df9e67e80acce1028c3dcbf0fcf |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFOUUyOjgxMzM0OjE0RTE2MDoxRDM3RDA6NkIwNDZGQkQiLCJ2aXNpdG9yX2lkIjoiMTk1Mjk4NzM2MTQ2NjE1MDg0NSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 03cf1641772ad7aa4307b66c920dfc4cd64cbec2f3228e21148e917e850b9692 |
| hovercard-subject-tag | issue:1317355532 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/getsentry/sentry-javascript/5462/issue_layout |
| twitter:image | https://opengraph.githubassets.com/8c27bc5d376127c2ae526929ad773e938590a9fbd91e09b4421658d86ddc8c3c/getsentry/sentry-javascript/issues/5462 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/8c27bc5d376127c2ae526929ad773e938590a9fbd91e09b4421658d86ddc8c3c/getsentry/sentry-javascript/issues/5462 |
| og:image:alt | Problem Statement Web Vitals v3 is currently in beta. Allows us to start tracking INP, which can replace FID. https://web.dev/inp/ Writing your own PerformanceObserver to measure INP can be difficu... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | AbhiPrasad |
| hostname | github.com |
| expected-hostname | github.com |
| None | ae8802492f12d3ba4f6b0d814054e617a2a5616b6327bf8555c10cd5b0dc2a6f |
| turbo-cache-control | no-preview |
| go-import | github.com/getsentry/sentry-javascript git https://github.com/getsentry/sentry-javascript.git |
| octolytics-dimension-user_id | 1396951 |
| octolytics-dimension-user_login | getsentry |
| octolytics-dimension-repository_id | 3328572 |
| octolytics-dimension-repository_nwo | getsentry/sentry-javascript |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 3328572 |
| octolytics-dimension-repository_network_root_nwo | getsentry/sentry-javascript |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | cfb5f24c6e01d85f70804652a5107e5cac03a161 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width