From 104df63aa97d32560d6a85129b02463605dc98c7 Mon Sep 17 00:00:00 2001 From: Lukas Stracke Date: Wed, 29 May 2024 10:19:00 +0200 Subject: [PATCH] meta: Add Changelog entry for 8.6.0 --- CHANGELOG.md | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4b9edfc5bd99..ef27de884501 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,60 @@ - "You miss 100 percent of the chances you don't take. — Wayne Gretzky" — Michael Scott +## 8.6.0 + +### Important Changes + +- **feat(metrics): Add `timings` method to metrics (#12226)** + + This introduces a new method, `metrics.timing()`, which can be used in two ways: + + 1. With a numeric value, to simplify creating a distribution metric. This will default to `second` as unit: + + ```js + Sentry.metrics.timing('myMetric', 100); + ``` + + 2. With a callback, which will wrap the duration of the callback. This can accept a sync or async callback. It will + create an inactive span around the callback and at the end emit a metric with the duration of the span in seconds: + + ```js + const returnValue = Sentry.metrics.timing('myMetric', measureThisFunction); + ``` + +- **feat(react): Add `Sentry.reactErrorHandler` (#12147)** + + This PR introduces `Sentry.reactErrorHandler`, which you can use as follows: + + ```js + import * as Sentry from '@sentry/react'; + import { hydrateRoot } from 'react-dom/client'; + + ReactDOM.hydrateRoot( + document.getElementById('root'), + + + , + { + onUncaughtError: Sentry.reactErrorHandler(), + onCaughtError: Sentry.reactErrorHandler((error, errorInfo) => { + // optional callback if users want custom config. + }), + }, + ); + ``` + + For more details, take a look at [the PR](https://github.com/getsentry/sentry-javascript/pull/12147) - docs will + follow soon! + +### Other Changes + +- feat(sveltekit): Add request data to server-side events (#12254) +- fix(core): Pass in cron monitor config correctly (#12248) +- fix(nextjs): Don't capture suspense errors in server components (#12261) +- fix(tracing): Ensure sent spans are limited to 1000 (#12252) +- ref(core): Use versioned carrier on global object (#12206) + ## 8.5.0 ### Important Changes