按照官方的文档进行了 跳转。 提示小程序尚未发布。在模拟器中显示。 Error: fail to open 合作伙伴的 微信小店已经运营很久了
、
wx.navigateToMiniProgram({
appId:x xxxxxx','
path: '/pages/index/index', // 目标页面路径及参数
extraData: { foo: 'bar' }, // 可选,传递给目标小程序的数据
envVersion: 'release', // 目标小程序版本(develop/trial/release)
success(res) { /* 跳转成功 */ },
fail(err) { /* 跳转失败 */ }
});

微信小店是一个特殊的小程序,不能用API跳转,目前只能通过提供的组件跳转
参考:https://developers.weixin.qq.com/miniprogram/dev/component/store-home.html
目标appid:wxfab7f857b94129e4
wx.navigateToMiniProgram({
appId:'wxfab7f857b94129e4',
path: '/pages/index/index', // 目标页面路径及参数
extraData: { foo: 'bar' }, // 可选,传递给目标小程序的数据
envVersion: 'release', // 目标小程序版本(develop/trial/release)
success(res) { /* 跳转成功 */ },
fail(err) { /* 跳转失败 */ }
});
目前合作伙伴的 店铺
完整的错误代码
Error: fail to open
at new <anonymous> (WAServiceMainContext.js?t=wechat&v=3.8.12:1)
at Function.fail (WAServiceMainContext.js?t=wechat&v=3.8.12:1)
at p (WAServiceMainContext.js?t=wechat&v=3.8.12:1)
at Object.fail (WAServiceMainContext.js?t=wechat&v=3.8.12:1)
at lp (WAServiceMainContext.js?t=wechat&v=3.8.12:1)
at dp (WAServiceMainContext.js?t=wechat&v=3.8.12:1)
at WAServiceMainContext.js?t=wechat&v=3.8.12:1
at r (WAServiceMainContext.js?t=wechat&v=3.8.12:1)
at s (WAServiceMainContext.js?t=wechat&v=3.8.12:1)
at index.js:1(env: macOS,mp,2.01.2510250; lib: 3.8.12)