Files
bilibili-subtitle/src/messaging/const.ts
IndieKKY 6c008feb3f 优化
2024-10-06 12:35:35 +08:00

18 lines
329 B
TypeScript

// 请求信息
export type L2ReqMsg = {
from: 'extension' | 'inject' | 'app'
target: string
method: string
params?: any
// [key: string]: any
}
// 响应信息
export type L2ResMsg<L2Res = any> = {
code: number
message?: string
data?: L2Res
}
export const MESSAGE_TO_EXTENSION_ROUTE_MSG = 'routeMsg'