We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents c9a5204 + 296aaee commit 1d95523Copy full SHA for 1d95523
frontend/packages/console-telemetry-plugin/src/listeners/usage.ts
@@ -1,11 +1,12 @@
1
import { TelemetryEventListener } from '@console/dynamic-plugin-sdk/src';
2
+import { coFetch } from '@console/internal/co-fetch';
3
4
/**
5
* Fire and forget implementation to send usage data to the backend.
6
* See pkg/usage/ for more information.
7
*/
8
const trackUsage = (data: { event: string; perspective: string }) => {
- return fetch('/metrics/usage', {
9
+ return coFetch('/metrics/usage', {
10
method: 'POST',
11
body: JSON.stringify(data),
12
})
0 commit comments