Object.defineProperty(exports, '__esModule', { value: true }); const core = require('@sentry/core'); const vercelEdge = require('@sentry/vercel-edge'); const isBuild = require('../common/utils/isBuild.js'); const rewriteFramesIntegration = require('./rewriteFramesIntegration.js'); const wrapGetStaticPropsWithSentry = require('../common/wrapGetStaticPropsWithSentry.js'); const wrapGetInitialPropsWithSentry = require('../common/wrapGetInitialPropsWithSentry.js'); const wrapAppGetInitialPropsWithSentry = require('../common/wrapAppGetInitialPropsWithSentry.js'); const wrapDocumentGetInitialPropsWithSentry = require('../common/wrapDocumentGetInitialPropsWithSentry.js'); const wrapErrorGetInitialPropsWithSentry = require('../common/wrapErrorGetInitialPropsWithSentry.js'); const wrapGetServerSidePropsWithSentry = require('../common/wrapGetServerSidePropsWithSentry.js'); const wrapServerComponentWithSentry = require('../common/wrapServerComponentWithSentry.js'); const wrapRouteHandlerWithSentry = require('../common/wrapRouteHandlerWithSentry.js'); const wrapApiHandlerWithSentryVercelCrons = require('../common/wrapApiHandlerWithSentryVercelCrons.js'); const wrapMiddlewareWithSentry = require('../common/wrapMiddlewareWithSentry.js'); const wrapPageComponentWithSentry = require('../common/wrapPageComponentWithSentry.js'); const wrapGenerationFunctionWithSentry = require('../common/wrapGenerationFunctionWithSentry.js'); const withServerActionInstrumentation = require('../common/withServerActionInstrumentation.js'); const wrapApiHandlerWithSentry = require('./wrapApiHandlerWithSentry.js'); /** Inits the Sentry NextJS SDK on the Edge Runtime. */ function init(options = {}) { core.addTracingExtensions(); if (isBuild.isBuild()) { return; } const customDefaultIntegrations = [...vercelEdge.getDefaultIntegrations(options), rewriteFramesIntegration.rewriteFramesIntegration()]; const opts = { defaultIntegrations: customDefaultIntegrations, ...options, }; core.applySdkMetadata(opts, 'nextjs'); vercelEdge.init(opts); } /** * Just a passthrough in case this is imported from the client. */ function withSentryConfig(exportedUserNextConfig) { return exportedUserNextConfig; } exports.Span = core.Span; exports.Transaction = core.Transaction; exports.rewriteFramesIntegration = rewriteFramesIntegration.rewriteFramesIntegration; exports.withSentryGetStaticProps = wrapGetStaticPropsWithSentry.withSentryGetStaticProps; exports.wrapGetStaticPropsWithSentry = wrapGetStaticPropsWithSentry.wrapGetStaticPropsWithSentry; exports.withSentryServerSideGetInitialProps = wrapGetInitialPropsWithSentry.withSentryServerSideGetInitialProps; exports.wrapGetInitialPropsWithSentry = wrapGetInitialPropsWithSentry.wrapGetInitialPropsWithSentry; exports.withSentryServerSideAppGetInitialProps = wrapAppGetInitialPropsWithSentry.withSentryServerSideAppGetInitialProps; exports.wrapAppGetInitialPropsWithSentry = wrapAppGetInitialPropsWithSentry.wrapAppGetInitialPropsWithSentry; exports.withSentryServerSideDocumentGetInitialProps = wrapDocumentGetInitialPropsWithSentry.withSentryServerSideDocumentGetInitialProps; exports.wrapDocumentGetInitialPropsWithSentry = wrapDocumentGetInitialPropsWithSentry.wrapDocumentGetInitialPropsWithSentry; exports.withSentryServerSideErrorGetInitialProps = wrapErrorGetInitialPropsWithSentry.withSentryServerSideErrorGetInitialProps; exports.wrapErrorGetInitialPropsWithSentry = wrapErrorGetInitialPropsWithSentry.wrapErrorGetInitialPropsWithSentry; exports.withSentryGetServerSideProps = wrapGetServerSidePropsWithSentry.withSentryGetServerSideProps; exports.wrapGetServerSidePropsWithSentry = wrapGetServerSidePropsWithSentry.wrapGetServerSidePropsWithSentry; exports.wrapServerComponentWithSentry = wrapServerComponentWithSentry.wrapServerComponentWithSentry; exports.wrapRouteHandlerWithSentry = wrapRouteHandlerWithSentry.wrapRouteHandlerWithSentry; exports.wrapApiHandlerWithSentryVercelCrons = wrapApiHandlerWithSentryVercelCrons.wrapApiHandlerWithSentryVercelCrons; exports.wrapMiddlewareWithSentry = wrapMiddlewareWithSentry.wrapMiddlewareWithSentry; exports.wrapPageComponentWithSentry = wrapPageComponentWithSentry.wrapPageComponentWithSentry; exports.wrapGenerationFunctionWithSentry = wrapGenerationFunctionWithSentry.wrapGenerationFunctionWithSentry; exports.withServerActionInstrumentation = withServerActionInstrumentation.withServerActionInstrumentation; exports.withSentryAPI = wrapApiHandlerWithSentry.withSentryAPI; exports.wrapApiHandlerWithSentry = wrapApiHandlerWithSentry.wrapApiHandlerWithSentry; exports.init = init; exports.withSentryConfig = withSentryConfig; for (const k in vercelEdge) { if (k !== 'default' && !exports.hasOwnProperty(k)) exports[k] = vercelEdge[k]; } //# sourceMappingURL=index.js.map