Skip to content

[Bug Report] @vant/area-data package.json 文件未定义 miniprogram 属性,导致微信小程序无法正常构建npm #6051

@styzy

Description

@styzy

重现链接

{
"name": "@vant/area-data",
"version": "2.1.0",
"description": "Vant 省市区数据",
"type": "module",
"main": "dist/index.cjs",
"module": "dist/index.js",
"types": "dist/index.d.ts",
"exports": {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.js",
"require": "./dist/index.cjs"
},
"./package.json": "./package.json"
},
"sideEffects": false,
"files": [
"dist"
],
"publishConfig": {
"access": "public",
"registry": "https://registry.npmjs.org/"
},
"repository": {
"type": "git",
"url": "https://github.com/vant-ui/vant.git",
"directory": "packages/vant-area-data"
},
"bugs": "https://github.com/vant-ui/vant/issues",
"author": "chenjiahan",
"license": "MIT",
"devDependencies": {
"@rslib/core": "^0.12.1",
"typescript": "^5.8.3"
},
"scripts": {
"dev": "rslib build -w",
"build": "rslib build",
"release": "vant-cli release"
}
}

Vant Weapp 版本

2.x

描述一下你遇到的问题。

希望加上微信小程序构建npm的属性
"miniprogram": "dist",

重现步骤

构建npm失败,提示无法找到入口js

设备/浏览器

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions