收藏
回答

文件打包超限后,进行了分包,主包页面跳转分包页面无响应?

文件打包超限后,进行了分包,原来主包页面(tab页面)跳转另一个页面是用wx.navigateTo进行跳转

例如:

wx.navigateTo({

url: '/pages/para_set/para_set'

})

现在para_set页面在分包中了,此时点击 ,页面不会跳转了,应该怎么修改呢


回答关注问题邀请回答
收藏

5 个回答

  • linux🕷
    linux🕷
    04-21

    已经解决了


    04-21
    有用
    回复 1
    • 耳朵
      耳朵
      10-15
      怎么解决的 哥
      10-15
      回复
  • 海灰吸丶
    海灰吸丶
    2019-11-13

    从根目录写起

    2019-11-13
    有用
    回复 2
    • LY
      LY
      2019-11-13
      是从根目录写的   /pages_person_pages/discount/discount   ,跳过去是个空白页面,不是原来写好的
      2019-11-13
      回复
    • 耳朵
      耳朵
      10-15回复LY
      解决了吗
      10-15
      回复
  • o0o有脾气的酸奶
    o0o有脾气的酸奶
    2019-11-13

    你的pages/para_set/para_set不是在主包的pages中的吗

    2019-11-13
    有用
    回复 7
    • LY
      LY
      2019-11-13
      额,我只是随便选的一个路径举例,我实际点击的是跳转到pages_person/pages/discount/discount这个页面
      2019-11-13
      回复
    • o0o有脾气的酸奶
      o0o有脾气的酸奶
      2019-11-13回复LY
      2019-11-13
      回复
    • LY
      LY
      2019-11-13回复o0o有脾气的酸奶
      跳过去是个空白页面,那种新建好空白页面,不是原来写好的页面了
      2019-11-13
      回复
    • o0o有脾气的酸奶
      o0o有脾气的酸奶
      2019-11-13回复LY
      弄 个代码片段,看能不能复现
      2019-11-13
      回复
    • LY
      LY
      2019-11-14回复o0o有脾气的酸奶
      发现问题了,是页面上的问题,我还有个疑问,换成分包加载后,原来每个页面的路径是不是都必须一个一个去换啊
      2019-11-14
      回复
    查看更多(2)
  • LY
    LY
    2019-11-13

    {

    "pages": [


    "pages/subscribe/subscribe",

    "pages/matching/matching",

    "pages/answer/answer",

    "pages/person/person",

    "pages/project/project",


    "pages/login/login",

    "pages/register/register",

    "pages/forget/forget",

    "pages/para_set/para_set",

    "pages/answerpara/answerpara",

    "pages/policeInfo/policeInfo",

    "pages/subject/subject",

    "pages/analyzeURL/analyzeURL"

    ],

    "subPackages":[

    {

    "root": "pages_matching",

    "pages": [

    "pages/popup/popup"

    ]

    },

    {

    "root": "pages_answer",

    "pages": [

    "pages/star_answer/star_answer",

    "pages/answer_result/answer_result",

    "pages/answer_result2/answer_result2"

    ]

    },

    {

    "root": "pages_person",

    "pages": [

    "pages/personInfo/personInfo",

    "pages/companypara/companypara",

    "pages/companyInfo/companyInfo",

    "pages/companylist/companylist",

    "pages/test_apply/test_apply",

    "pages/answerdetail/answerdetail",

    "pages/feedback/feedback",

    "pages/itemprogress/itemprogress",

    "pages/evaluation/evaluation",

    "pages/discount/discount",

    "pages/coupon_detail/coupon_detail"

    ]

    }

    ],


    "window": {

    "navigationStyle": "custom"

    },

    "permission": {

    "scope.userLocation": {

    "desc": "你的位置信息将用于匹配当前地区的政策"

    }

    },

    "tabBar": {

    "list": [

    {

    "pagePath": "pages/subscribe/subscribe",

    "text": "政策汇",

    "iconPath": "pages/img/subscribe1.png",

    "selectedIconPath": "pages/img/subscribe2.png"

    },

    {

    "pagePath": "pages/matching/matching",

    "text": "资金评估",

    "iconPath": "pages/img/matching1.png",

    "selectedIconPath": "pages/img/matching2.png"

    },

    {

    "pagePath": "pages/project/project",

    "text": "立项查询",

    "iconPath": "pages/img/project1.png",

    "selectedIconPath": "pages/img/project2.png"

    },

    {

    "pagePath": "pages/answer/answer",

    "text": "测评系统",

    "iconPath": "pages/img/answer1.png",

    "selectedIconPath": "pages/img/answer2.png"

    },

    {

    "pagePath": "pages/person/person",

    "text": "会员中心",

    "iconPath": "pages/img/person1.png",

    "selectedIconPath": "pages/img/person2.png"

    }

    ],

    "selectedColor": "#f25050",

    "color": "#aaaaaa",

    "position": "bottom"

    },

    "sitemapLocation": "sitemap.json"

    }


    2019-11-13
    有用
    回复
  • 小满
    小满
    2019-11-13

    把配置文件贴处来吧

    2019-11-13
    有用
    回复 6
    • LY
      LY
      2019-11-13
      你好,贴出来了,你看看呢
      2019-11-13
      回复
    • 小满
      小满
      2019-11-13回复LY
      报错信息呢?找不到页面?
      2019-11-13
      回复
    • LY
      LY
      2019-11-13
      没有报错,原路跳转路径不变的话,就点不动,换成/pages_person/pages/discount/discount,跳过去就是个新页面,刚建好的那种样式,不是原来写好的那个页面了
      2019-11-13
      回复
    • 今夕何夕
      今夕何夕
      2023-08-04回复LY
      请问解决了吗,我跳转过去也是新建的空白页
      2023-08-04
      回复
    • Wonder
      Wonder
      2023-09-20回复LY
      请问解决了吗,我跳转过去也是新建的空白页
      2023-09-20
      回复
    查看更多(1)
登录 后发表内容
问题标签