Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

app-plus的webview中uni.getEnv是undefined #1011

Closed
lmf opened this issue Nov 18, 2019 · 3 comments
Closed

app-plus的webview中uni.getEnv是undefined #1011

lmf opened this issue Nov 18, 2019 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@lmf
Copy link

lmf commented Nov 18, 2019

问题描述
web-view组件中引用的网页加载了uni.webview.1.5.2.js,然后在UniAppJSBridgeReady事件回调中执行uni.getEnv时候报undefined

补充信息
[可选]
看了下uni js sdk的代码,判断如果该h5页面是uni-app生成的,则uni-app的api会覆盖js sdk上的,建议js sdk上的api挂到uni的子属性下如uni.sdk

@lmf
Copy link
Author

lmf commented Nov 18, 2019

这问题只有h5页面是用uni-app生成的且引用了uni的js sdk后会有

@lmf
Copy link
Author

lmf commented Nov 19, 2019

@fxy060608 帮忙看下这个问题

@fxy060608 fxy060608 self-assigned this Nov 19, 2019
@fxy060608 fxy060608 added the bug Something isn't working label Nov 19, 2019
fxy060608 added a commit that referenced this issue Nov 20, 2019
@dcloudhdx
Copy link
Contributor

已更新线上的 uni.webview.1.5.2.js

@lmf lmf closed this as completed Jan 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants