manifest.json配置
"mp-alipay" : {
"usingComponents" : true,
"include" : [ "**/*.xml" ],
"appid" : ""
} 产品分类: uniapp/小程序/阿里
PC开发环境操作系统: Windows
PC开发环境操作系统版本号: win10家庭中文版21H2
HBuilderX类型: 正式
HBuilderX版本号: 3.7.10
第三方开发者工具版本号: 3.6.3
基础库版本号: 2.0
项目创建方式: HBuilderX
manifest.json配置
"mp-alipay" : {
"usingComponents" : true,
"include" : [ "**/*.xml" ],
"appid" : ""
} mini.project.json
{
"include": [
"**/*.xml"
],
"component2": true,
"enableAppxNg": true
} mini.project.json
{
"component2": true,
"enableAppxNg": true
} 打包支付宝小程序配置'include" : [ "*/.xml" ]'后没有把该配置编译到mini.project.json中,导致支付宝小程序地图标记marker不显示
xbuilder安装目录下 HBuilderX\plugins\uniapp-cli\node_modules\@dcloudio\webpack-uni-pages-loader\lib\platforms\mp-alipay.js修改
if (fs.existsSync(projectPath)) {
project = require(projectPath)
} else {
project.component2 = hasOwn(platformJson, 'component2') ? platformJson.component2 : true
project.enableAppxNg = hasOwn(platformJson, 'enableAppxNg') ? platformJson.enableAppxNg : true
}
为
if (fs.existsSync(projectPath)) {
project = require(projectPath)
} else {
project["include"]=["**/*.xml"]
project.component2 = hasOwn(platformJson, 'component2') ? platformJson.component2 : true
project.enableAppxNg = hasOwn(platformJson, 'enableAppxNg') ? platformJson.enableAppxNg : true
}
支付宝小程序地图相关文档:https://opendocs.alipay.com/mini/component/00n21l 使用限制栏
请技术人员调试后该方案后及时处理并发布新版本
1 个回复
DCloud_UNI_WZF
针对 manifest.json 中不支持小程序部分配置的情况,可通过自定义小程序项目配置 方案解决