찾다

 >  Q&A  >  본문

weex中打包js到原生android中调用weex.config.bundleUrl无效

各位好!本人使用Weex开发app,在weex提供的Playground里面可以获取到当前的bundleUrl,调用方式:
weex.config.bundleUrl或者this.$getConfig().bundleUrl。但是当把js打包到原生android里面的时候,发现没有bundleUrl了,只有env对象。请问各位该如何处理?

PHPzPHPz2893일 전1004

모든 응답(1)나는 대답할 것이다

  • 阿神

    阿神2017-04-18 09:17:50

    WXSDKInstance에서 render 메소드를 살펴봐야 하는데, playground는 이 메소드 호출 시 options 매개변수가 설정되어 있기 때문에 얻을 수 있다.

    으아악

    위의 의사코드와 유사합니다.

    회신하다
    0
  • 취소회신하다