@@ -521,25 +521,26 @@ class PluginContext implements Omit<RollupPluginContext, 'cache'> {
521521 return this . _container . getModuleInfo ( id )
522522 }
523523
524+ // @ts -expect-error
524525 async resolve (
525526 id : string ,
526527 importer ?: string ,
527528 options ?: {
528- // attributes?: Record<string, string>
529- // custom?: CustomPluginOptions
530- // isEntry?: boolean
531- // skipSelf?: boolean
529+ attributes ?: Record < string , string >
530+ custom ?: CustomPluginOptions
531+ isEntry ?: boolean
532+ skipSelf ?: boolean
532533 } ,
533534 ) : ReturnType < RollupPluginContext [ 'resolve' ] > {
534535 let skip : Set < Plugin > | undefined
535- // if (options?.skipSelf !== false && this._plugin) {
536- // skip = new Set(this._resolveSkips)
537- // skip.add(this._plugin)
538- // }
536+ if ( options ?. skipSelf !== false && this . _plugin ) {
537+ skip = new Set ( this . _resolveSkips )
538+ skip . add ( this . _plugin )
539+ }
539540 let out = await this . _container . resolveId ( id , importer , {
540- // attributes: options?.attributes,
541- // custom: options?.custom,
542- // isEntry: !!options?.isEntry,
541+ attributes : options ?. attributes ,
542+ custom : options ?. custom ,
543+ isEntry : ! ! options ?. isEntry ,
543544 skip,
544545 ssr : this . ssr ,
545546 scan : this . _scan ,
@@ -793,6 +794,7 @@ class LoadPluginContext extends PluginContext {
793794 }
794795}
795796
797+ // @ts -expect-error
796798class TransformPluginContext
797799 extends LoadPluginContext
798800 implements Omit < RollupTransformPluginContext , 'cache' >
0 commit comments