@lookiero/checkout 0.6.0-beta.34 → 0.6.0-beta.35
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/shared/logging/SentryDependencies.d.ts +3 -3
- package/dist/shared/logging/SentryDependencies.js +1 -1
- package/dist/shared/logging/SentryDependencies.native.d.ts +3 -3
- package/dist/shared/logging/SentryDependencies.native.js +2 -2
- package/dist/shared/logging/SentryLogger.js +1 -5
- package/dist/shared/logging/reactRouterV6Instrumentation/reactRouterV6Instrumentation.native.d.ts +7 -0
- package/dist/shared/logging/reactRouterV6Instrumentation/reactRouterV6Instrumentation.native.js +7 -0
- package/dist/shared/logging/types.d.ts +5 -1
- package/package.json +1 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { BrowserClient, Hub } from "@sentry/browser";
|
|
2
2
|
import { ErrorBoundary } from "@sentry/react";
|
|
3
3
|
import { ReactNativeTransportOptions } from "@sentry/react-native/dist/js/options";
|
|
4
|
-
import { Transport
|
|
5
|
-
import { WrapComponent, WrapUseRoutes } from "./types";
|
|
4
|
+
import { Transport } from "@sentry/types";
|
|
5
|
+
import { Integrations, WrapComponent, WrapUseRoutes } from "./types";
|
|
6
6
|
declare const transport: (options: ReactNativeTransportOptions) => Transport;
|
|
7
|
-
declare const integrations:
|
|
7
|
+
declare const integrations: Integrations;
|
|
8
8
|
declare const wrapComponent: WrapComponent;
|
|
9
9
|
declare const wrapUseRoutes: WrapUseRoutes;
|
|
10
10
|
export { BrowserClient as Client, Hub, ErrorBoundary, transport, integrations, wrapComponent, wrapUseRoutes };
|
|
@@ -7,7 +7,7 @@ import { useEffect } from "react";
|
|
|
7
7
|
import { createRoutesFromChildren, useLocation, useNavigationType } from "react-router-native";
|
|
8
8
|
import { matchRoutes } from "./matchRoutes";
|
|
9
9
|
const transport = (options, nativeFetch) => makeFetchTransport(options, nativeFetch);
|
|
10
|
-
const integrations = [
|
|
10
|
+
const integrations = () => [
|
|
11
11
|
...defaultIntegrations,
|
|
12
12
|
new BrowserTracing({
|
|
13
13
|
routingInstrumentation: reactRouterV6Instrumentation(useEffect, useLocation, useNavigationType, createRoutesFromChildren, matchRoutes),
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { ReactNativeClient, Hub, ErrorBoundary } from "@sentry/react-native";
|
|
2
2
|
import { ReactNativeTransportOptions } from "@sentry/react-native/dist/js/options";
|
|
3
|
-
import { Transport
|
|
4
|
-
import { WrapComponent, WrapUseRoutes } from "./types";
|
|
3
|
+
import { Transport } from "@sentry/types";
|
|
4
|
+
import { Integrations, WrapComponent, WrapUseRoutes } from "./types";
|
|
5
5
|
declare const transport: (options: ReactNativeTransportOptions) => Transport;
|
|
6
|
-
declare const integrations:
|
|
6
|
+
declare const integrations: Integrations;
|
|
7
7
|
declare const wrapComponent: WrapComponent;
|
|
8
8
|
declare const wrapUseRoutes: WrapUseRoutes;
|
|
9
9
|
export { ReactNativeClient as Client, Hub, ErrorBoundary, transport, integrations, wrapComponent, wrapUseRoutes };
|
|
@@ -7,7 +7,7 @@ import { useLocation } from "react-router-native";
|
|
|
7
7
|
import { matchRoutes } from "./matchRoutes";
|
|
8
8
|
import { ReactRouterV6Instrumentation } from "./reactRouterV6Instrumentation/reactRouterV6Instrumentation.native";
|
|
9
9
|
const transport = (options, nativeFetch) => {
|
|
10
|
-
console.log("NATIVE.isNativeTransportAvailable()", NATIVE.isNativeTransportAvailable());
|
|
10
|
+
console.log("NATIVE.isNativeTransportAvailable()", NATIVE.isNativeTransportAvailable(), options, nativeFetch);
|
|
11
11
|
console.log(makeReactNativeTransport(options));
|
|
12
12
|
console.log(makeFetchTransport(options, nativeFetch));
|
|
13
13
|
return NATIVE.isNativeTransportAvailable()
|
|
@@ -15,7 +15,7 @@ const transport = (options, nativeFetch) => {
|
|
|
15
15
|
: makeFetchTransport(options, nativeFetch);
|
|
16
16
|
};
|
|
17
17
|
const routingInstrumentation = new ReactRouterV6Instrumentation(useEffect, useLocation, matchRoutes);
|
|
18
|
-
const integrations = [new ReactNativeTracing({ routingInstrumentation })];
|
|
18
|
+
const integrations = () => [new ReactNativeTracing({ routingInstrumentation })];
|
|
19
19
|
const wrapComponent = (Component) => sentryWrap(Component);
|
|
20
20
|
const wrapUseRoutes = routingInstrumentation.wrapUseRoutes.bind(routingInstrumentation);
|
|
21
21
|
export { ReactNativeClient as Client, Hub, ErrorBoundary, transport, integrations, wrapComponent, wrapUseRoutes };
|
|
@@ -10,7 +10,7 @@ const sentryLogger = ({ publicKey, environment, release, project }) => {
|
|
|
10
10
|
environment,
|
|
11
11
|
release,
|
|
12
12
|
dsn: `https://${publicKey}@o179049.ingest.sentry.io/${project}`,
|
|
13
|
-
integrations,
|
|
13
|
+
integrations: integrations(),
|
|
14
14
|
tracesSampleRate: 1.0,
|
|
15
15
|
debug: true,
|
|
16
16
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
@@ -66,10 +66,6 @@ const sentryLogger = ({ publicKey, environment, release, project }) => {
|
|
|
66
66
|
/webappstoolbarba\.texthelp\.com\//i,
|
|
67
67
|
/metrics\.itunes\.apple\.com\.edgesuite\.net\//i,
|
|
68
68
|
],
|
|
69
|
-
beforeSendTransaction: (event, hint) => {
|
|
70
|
-
console.log(event, hint);
|
|
71
|
-
return event;
|
|
72
|
-
},
|
|
73
69
|
});
|
|
74
70
|
const hub = new Hub(client);
|
|
75
71
|
const onMount = (customerId) => {
|
package/dist/shared/logging/reactRouterV6Instrumentation/reactRouterV6Instrumentation.native.d.ts
CHANGED
|
@@ -2,6 +2,13 @@ import { RoutingInstrumentation } from "@sentry/react-native";
|
|
|
2
2
|
import { OnConfirmRoute, TransactionCreator } from "@sentry/react-native/dist/js/tracing/routingInstrumentation";
|
|
3
3
|
import { BeforeNavigate } from "@sentry/react-native/dist/js/tracing/types";
|
|
4
4
|
import { MatchRoutes, UseEffect, UseLocation, WrapUseRoutes } from "../types";
|
|
5
|
+
/**
|
|
6
|
+
* This instrumentation has been built following the actual
|
|
7
|
+
* ReactNavigationV4Instrumentation implementation as suggested in the documentation.
|
|
8
|
+
*
|
|
9
|
+
* (https://docs.sentry.io/platforms/react-native/performance/instrumentation/automatic-instrumentation/#custom-instrumentation)
|
|
10
|
+
* (https://github.com/getsentry/sentry-react-native/blob/211ec081b6bf8d7d29541afe9d800040f61e3c4e/src/js/tracing/reactnavigationv4.ts)
|
|
11
|
+
*/
|
|
5
12
|
declare class ReactRouterV6Instrumentation extends RoutingInstrumentation {
|
|
6
13
|
static instrumentationName: string;
|
|
7
14
|
private useEffect;
|
package/dist/shared/logging/reactRouterV6Instrumentation/reactRouterV6Instrumentation.native.js
CHANGED
|
@@ -4,6 +4,13 @@ import { logger } from "@sentry/utils";
|
|
|
4
4
|
import React from "react";
|
|
5
5
|
import { normalizedNameAndMatchForLocation } from "./normalizedNameAndMatchForLocation";
|
|
6
6
|
import { transactionContext } from "./transactionContext";
|
|
7
|
+
/**
|
|
8
|
+
* This instrumentation has been built following the actual
|
|
9
|
+
* ReactNavigationV4Instrumentation implementation as suggested in the documentation.
|
|
10
|
+
*
|
|
11
|
+
* (https://docs.sentry.io/platforms/react-native/performance/instrumentation/automatic-instrumentation/#custom-instrumentation)
|
|
12
|
+
* (https://github.com/getsentry/sentry-react-native/blob/211ec081b6bf8d7d29541afe9d800040f61e3c4e/src/js/tracing/reactnavigationv4.ts)
|
|
13
|
+
*/
|
|
7
14
|
class ReactRouterV6Instrumentation extends RoutingInstrumentation {
|
|
8
15
|
static instrumentationName = "react-router-v6";
|
|
9
16
|
useEffect;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { Integration } from "@sentry/types";
|
|
1
2
|
import { ComponentType, useEffect } from "react";
|
|
2
3
|
import { matchRoutes, RouteObject, useLocation } from "react-router-native";
|
|
3
4
|
interface Location {
|
|
@@ -13,4 +14,7 @@ interface WrapUseRoutes {
|
|
|
13
14
|
interface WrapComponent {
|
|
14
15
|
<P>(Component: ComponentType<P>): ComponentType<P>;
|
|
15
16
|
}
|
|
16
|
-
|
|
17
|
+
interface Integrations {
|
|
18
|
+
(): Integration[];
|
|
19
|
+
}
|
|
20
|
+
export type { Location, Integrations, UseEffect, UseLocation, MatchRoutes, UseRoutes, WrapUseRoutes, WrapComponent };
|