智能照明系统APP-本地串口
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
LightingSystemApp-serial/.svn/pristine/a0/a0b2fbc498399fc40d9df95dd3f...

32 lines
583 B

const isQuickapp = window.qa &&
/quickapp/i.test(navigator.userAgent)
export function initWebviewApi (readyCallback) {
if (!isQuickapp) {
return
}
if (window.QaJSBridge && window.QaJSBridge.invoke) {
setTimeout(readyCallback, 0)
} else {
document.addEventListener('QaJSBridgeReady', readyCallback)
}
const {
navigateTo,
navigateBack,
switchTab,
reLaunch,
redirectTo,
postMessage,
getEnv
} = window.qa
return {
navigateTo,
navigateBack,
switchTab,
reLaunch,
redirectTo,
postMessage,
getEnv
}
}