client.js 937 B

123456789101112131415161718192021222324252627282930313233
  1. Object.defineProperty(exports, '__esModule', { value: true });
  2. const core = require('@sentry/core');
  3. /**
  4. * The Sentry Vercel Edge Runtime SDK Client.
  5. *
  6. * @see VercelEdgeClientOptions for documentation on configuration options.
  7. * @see ServerRuntimeClient for usage documentation.
  8. */
  9. class VercelEdgeClient extends core.ServerRuntimeClient {
  10. /**
  11. * Creates a new Vercel Edge Runtime SDK instance.
  12. * @param options Configuration options for this SDK.
  13. */
  14. constructor(options) {
  15. core.applySdkMetadata(options, 'vercel-edge');
  16. options._metadata = options._metadata || {};
  17. const clientOptions = {
  18. ...options,
  19. platform: 'javascript',
  20. // TODO: Grab version information
  21. runtime: { name: 'vercel-edge' },
  22. serverName: options.serverName || process.env.SENTRY_NAME,
  23. };
  24. super(clientOptions);
  25. }
  26. }
  27. exports.VercelEdgeClient = VercelEdgeClient;
  28. //# sourceMappingURL=client.js.map