https://developers.weixin.qq.com/miniprogram/dev/devtools/ext.html中的配置错误,正确的如下plugins的位置错了
{
"extEnable": true,
"extAppid": "wxf9c4501a76931b33",
"directCommit": false,
"ext": {
"name": "wechat",
"attr": {
"host": "open.weixin.qq.com",
"users": [
"user_1",
"user_2"
]
}
},
"extPages": {
"pages/logs/logs": {
"navigationBarTitleText": "logs"
}
},
"window":{
"backgroundTextStyle":"light",
"navigationBarBackgroundColor": "#fff",
"navigationBarTitleText": "Demo",
"navigationBarTextStyle":"black"
},
"tabBar": {
"list": [{
"pagePath": "pages/index/index",
"text": "首页"
}, {
"pagePath": "pages/logs/logs",
"text": "日志"
}]
},
"networkTimeout": {
"request": 10000,
"downloadFile": 10000
},
"plugins": {
"myPlugin": {
"version": "1.0.0",
"provider": "wxidxxxxxxxxxxxxxxxx"
}
}
}

你好,1、是指文档示例提供的多个一个{}吗?
2、以前有区分标准模板和普通模板,标准模板支持的参数只有:
标准模板依赖交易组件,但是交易组件已经下架,因此建议开发者这边使用普通模板,无法再使用标准模板
https://developers.weixin.qq.com/community/develop/doc/000444efe4c328cfd851d6f1766c00
另外,plugins是放置在ext_json参数下的
回复第二个答复:标准模板中如果要动态分配plugins是否无法实现
回复第三个答复:现在交易组件已重新上架了,在mp中可以选择,如果使用普通模板都无法配置ext_json,所以这个ext_json的那么多参数是否没有只能用{"extAppid":" ", "ext": {}, "window": {}}
需要动态配置plugins的原因:开发的小程序只做开发使用,很多插件无法添加并上传到微信开放平台,例如微信物流查询插件(需要小程序存在交易才能申请使用)这种情况如何上传带插件的模板到草稿
普通模板在上传代码时可以配置ext_json,此参数必填,ext_json用于控制ext.json配置内容
通过commit接口提交版本到小程序
提交格式为
{"template_id":3,"user_version":"1.1.3","ext_json":"{\"extAppid\":\"wx99733b1b820895cb\",\"ext\":{\"site_id\":10000},\"0\":{\"plugins\":{\"logisticsPlugin\":{\"provider\":\"wx9ad912bf20548d92\",\"version\":\"2.1.5\"}}}}"}接口返回
{"template_id":3,"user_version":"1.1.3","ext_json":"{\"extAppid\":\"wx99733b1b820895cb\",\"ext\":{\"site_id\":10000},\"plugins\":{\"logisticsPlugin\":{\"provider\":\"wx9ad912bf20548d92\",\"version\":\"2.1.5\"}}}"}标准模板extjson错误! rid: 68237677-1a2729ec-39fabb98