安装

环境要求

auto-exhibition-template-sdk 对运行环境有以下要求:

  • Node.js:>= 16.x
  • Vue:>= 3.5.32
  • Vite:>= 8.0.4

包管理器

推荐使用 pnpm 或 npm 安装 SDK。

pnpm(推荐)

pnpm add auto-exhibition-template-sdk

npm

npm install auto-exhibition-template-sdk

npm 发布说明

SDK 通过 npm 公开注册表发布,可以直接使用包管理器安装。

提示: 升级 SDK 版本时,重新执行安装命令并指定新版本号,或使用 pnpm update auto-exhibition-template-sdk 更新到最新版本。

IDE 配置

为了获得最佳的 TypeScript 类型提示和编辑器支持,建议在项目中添加 jsconfig.jsontsconfig.json 配置:

jsconfig.json

{
  "include": [
    ".auto-exhibition-template-sdk/**/*.d.ts"
  ]
}

tsconfig.json

{
  "include": [
    ".auto-exhibition-template-sdk/**/*.d.ts"
  ]
}
提示: include 中加入 SDK 类型声明后,编辑器可以识别当前 configJson 对应的字段路径和返回值类型。

下一步

安装完成后,请继续阅读 快速开始 了解如何使用 SDK。