File tree Expand file tree Collapse file tree
packages/rollup-plugin/src Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ import {
1515 CodeInjection ,
1616} from "@sentry/bundler-plugin-core" ;
1717import MagicString , { SourceMap } from "magic-string" ;
18- import type { TransformHook } from "rollup" ;
18+ import type { TransformResult } from "rollup" ;
1919import * as path from "node:path" ;
2020import { createRequire } from "node:module" ;
2121
@@ -125,14 +125,12 @@ export function _rollupPluginInternal(
125125 } ) ;
126126 }
127127
128- function transform ( code : string , id : string ) : ReturnType < TransformHook > {
128+ async function transform ( code : string , id : string ) : Promise < TransformResult > {
129129 // Component annotations are only in user code and boolean flag replacements are
130130 // only in Sentry code. If we successfully add annotations, we can return early.
131131
132132 if ( transformAnnotations ?. transform ) {
133- // eslint-disable-next-line @typescript-eslint/ban-ts-comment
134- // @ts -ignore TS complains about 'this'
135- const result = transformAnnotations . transform ( code , id ) ;
133+ const result = await transformAnnotations . transform ( code , id ) ;
136134 if ( result ) {
137135 return result ;
138136 }
You can’t perform that action at this time.
0 commit comments