import { bridge , BridgeMethods , SpecialMethods , Fn , APBridgeMethods } from '@goldfishjs/bridge' ; import Plugin , { GetPlugin } from './Plugin' ; export default class BridgePlugin extends Plugin { public static type = 'bridge' ; public async init ( _ ) { } public destroy ( ) { } public async call < T extends keyof R , R extends Record < string , any > = BridgeMethods & SpecialMethods > ( api , params ? ) { return bridge . call ( api , params ) ; } public async mycall < R , P = Record < string , any > > ( api , params ? ) { return bridge . mycall ( api , params ) ; } public async ap < T extends keyof R , R extends Record < string , Fn > = APBridgeMethods > ( api , params ? ) { return bridge . ap ( api , params ) ; } }