首页 > 其他 > 详细

cordova 热更新

时间:2020-06-06 13:52:31      阅读:49      评论:0      收藏:0      [点我收藏+]

1.根目录.chcpenv

{
  "content_url": "http://106.13.216.173:5636/hotpush",
  "config_url": "http://106.13.216.173:5636/hotpush/chcp.json"
}
// 线上
{
  "content_url": "https://app.xx.io",
  "config_url": "https://app.xx.io/chcp.json"
}

2.根目录.cordova-hcp.json

{
  "name": "alan",
  "ios_identifier": "",
  "android_identifier": "",
  "update": "resume",
  "content_url": "http://106.13.216.173:5636/hotpush"
}
// 线上
{
  "name": "xx",
  "ios_identifier": "",
  "android_identifier": "",
  "update": "start",
  "content_url": "https://app.xx.io"
}

3.根目录.config.xml

<chcp>
    <auto-download enabled="true" />
    <auto-install enabled="true" />
    <config-file url="http://106.13.216.173:5636/hotpush/chcp.json" />
    <native-interface version="1" />
</chcp>
// 线上
<chcp>
    <auto-download enabled="true" />
    <auto-install enabled="true" />
    <config-file url="https://app.xx.io/chcp.json" />
    <native-interface version="1" />
</chcp>

4.命令

cordova-hcp build

 

cordova 热更新

原文:https://www.cnblogs.com/alantao/p/13054325.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!