@sentry/wizard
Version:
Sentry wizard helping you to configure your project
53 lines (52 loc) • 3.93 kB
TypeScript
type WithSentryConfigOptions = {
orgSlug: string;
projectSlug: string;
selfHosted: boolean;
sentryUrl: string;
tunnelRoute: boolean;
};
export declare function getWithSentryConfigOptionsTemplate({ orgSlug, projectSlug, selfHosted, tunnelRoute, sentryUrl, }: WithSentryConfigOptions): string;
export declare function getNextjsConfigCjsTemplate(withSentryConfigOptionsTemplate: string): string;
export declare function getNextjsConfigMjsTemplate(withSentryConfigOptionsTemplate: string): string;
export declare function getNextjsConfigCjsAppendix(withSentryConfigOptionsTemplate: string): string;
export declare function getNextjsConfigEsmCopyPasteSnippet(withSentryConfigOptionsTemplate: string): string;
export declare function getSentryServersideConfigContents(dsn: string, config: 'server' | 'edge', selectedFeaturesMap: {
replay: boolean;
performance: boolean;
logs: boolean;
}): string;
export declare function getInstrumentationClientFileContents(dsn: string, selectedFeaturesMap: {
replay: boolean;
performance: boolean;
logs: boolean;
}): string;
export declare function getSentryExamplePageContents(options: {
selfHosted: boolean;
sentryUrl: string;
orgSlug: string;
projectId: string;
useClient: boolean;
isTypeScript?: boolean;
}): string;
export declare function getSentryExamplePagesDirApiRoute({ isTypeScript, }: {
isTypeScript: boolean;
}): string;
export declare function getSentryExampleAppDirApiRoute({ isTypeScript, }: {
isTypeScript: boolean;
}): string;
export declare function getSentryDefaultUnderscoreErrorPage(): string;
export declare function getSimpleUnderscoreErrorCopyPasteSnippet(): string;
export declare function getGenerateMetadataSnippet(isTs: boolean): string;
export declare function getFullUnderscoreErrorCopyPasteSnippet(isTs: boolean): string;
export declare function getInstrumentationHookContent(instrumentationHookLocation: 'src' | 'root'): string;
export declare function getInstrumentationHookCopyPasteSnippet(instrumentationHookLocation: 'src' | 'root'): string;
export declare function getInstrumentationClientHookCopyPasteSnippet(dsn: string, selectedFeaturesMap: {
replay: boolean;
performance: boolean;
logs: boolean;
}): string;
export declare function getSentryDefaultGlobalErrorPage(isTs: boolean): "\"use client\";\n\nimport * as Sentry from \"@sentry/nextjs\";\nimport NextError from \"next/error\";\nimport { useEffect } from \"react\";\n\nexport default function GlobalError({ error }: { error: Error & { digest?: string } }) {\n useEffect(() => {\n Sentry.captureException(error);\n }, [error]);\n\n return (\n <html>\n <body>\n {/* `NextError` is the default Next.js error page component. Its type\n definition requires a `statusCode` prop. However, since the App Router\n does not expose status codes for errors, we simply pass 0 to render a\n generic error message. */}\n <NextError statusCode={0} />\n </body>\n </html>\n );\n}" | "\"use client\";\n\nimport * as Sentry from \"@sentry/nextjs\";\nimport NextError from \"next/error\";\nimport { useEffect } from \"react\";\n\nexport default function GlobalError({ error }) {\n useEffect(() => {\n Sentry.captureException(error);\n }, [error]);\n\n return (\n <html>\n <body>\n {/* `NextError` is the default Next.js error page component. Its type\n definition requires a `statusCode` prop. However, since the App Router\n does not expose status codes for errors, we simply pass 0 to render a\n generic error message. */}\n <NextError statusCode={0} />\n </body>\n </html>\n );\n}\n";
export declare function getGlobalErrorCopyPasteSnippet(isTs: boolean): string;
export declare const getRootLayout: (isTs: boolean) => string;
export declare const getRootLayoutWithGenerateMetadata: (isTs: boolean) => string;
export {};