Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions dev-packages/browser-integration-tests/suites/wasm/init.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import * as Sentry from '@sentry/browser';
import { Wasm } from '@sentry/wasm';
import { wasmIntegration } from '@sentry/wasm';

window.Sentry = Sentry;

Sentry.init({
dsn: 'https://[email protected]/1337',
integrations: [new Wasm()],
integrations: [wasmIntegration()],
beforeSend: event => {
window.events.push(event);
return null;
Expand Down
23 changes: 2 additions & 21 deletions packages/wasm/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { convertIntegrationFnToClass, defineIntegration } from '@sentry/core';
import type { Event, Integration, IntegrationClass, IntegrationFn, StackFrame } from '@sentry/types';
import { defineIntegration } from '@sentry/core';
import type { Event, IntegrationFn, StackFrame } from '@sentry/types';

import { patchWebAssembly } from './patchWebAssembly';
import { getImage, getImages } from './registry';
Expand Down Expand Up @@ -35,25 +35,6 @@ const _wasmIntegration = (() => {

export const wasmIntegration = defineIntegration(_wasmIntegration);

/**
* Process WASM stack traces to support server-side symbolication.
*
* This also hooks the WebAssembly loading browser API so that module
* registrations are intercepted.
*
* @deprecated Use `wasmIntegration` export instead
*
* import { wasmIntegration } from '@sentry/wasm';
*
* ```
* Sentry.init({ integrations: [wasmIntegration()] });
* ```
*/
// eslint-disable-next-line deprecation/deprecation
export const Wasm = convertIntegrationFnToClass(INTEGRATION_NAME, wasmIntegration) as IntegrationClass<
Integration & { processEvent: (event: Event) => Event }
>;

/**
* Patches a list of stackframes with wasm data needed for server-side symbolication
* if applicable. Returns true if any frames were patched.
Expand Down