This commit is contained in:
IndieKKY
2024-10-06 12:35:35 +08:00
parent b91e1476d6
commit 6c008feb3f
6 changed files with 83 additions and 76 deletions

View File

@@ -0,0 +1,17 @@
// 请求信息
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'