npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

sapdon

v3.2.2

Published

Sapdon is a Node.js toolkit designed for building Bedrock Edition Minecraft addon packs.

Readme

Sapdon 框架

Sapdon Logo

Sapdon 是一个基于 JavaScript 开发的 Minecraft 基岩版模组开发框架。它通过提供丰富的 API 和自动化工具,帮助开发者简化传统开发流程,降低 JSON 配置复杂度,让您专注于模组逻辑实现。

Node.js Version npm Version QQ Group

✨ 核心特性

  • JavaScript 驱动开发 - 告别繁琐的 JSON 配置,使用现代 JS 语法编写模组
  • 模块化 API 设计 - 提供物品/方块/实体/配方等 30+ 核心 API 接口
  • 智能编译系统 - 一键生成标准 mcaddon 包文件

🚀 快速入门

环境准备

  1. 安装 Node.js (推荐 v16+)
  2. 安装 Visual Studio Code 或其他现代编辑器

安装 CLI

npm install -g sapdon

创建新项目

sapdon create hello_sapdon

根据提示输入项目信息:

✔ Project Name: hello_sapdon
✔ Project Description: 我的第一个 Sapdon 模组
✔ Author Name: YourName
✔ Project Version: 1.0.0
✔ Minimum Engine Version: 1.19.50

项目结构

hello_sapdon/
├── res/            # 资源文件(纹理/模型/音效)
├── scripts/        # 游戏脚本
├── build.config    # 构建配置
├── main.mjs        # 主入口文件
├── mod.info        # 模组元数据
└── pack_icon.png   # 模组图标

📦 核心 API 示例

创建一个基础物品

  1. 打开 main.mjs 文件。
  2. 写入以下内容以创建一个基础物品:
    import { ItemAPI } from "@sapdon/core";
    
    ItemAPI.createItem("hello_sapdon:my_item", "items", "masterball");
    这段代码将创建一个名为 my_item 的物品,其命名空间为 hello_sapdon,类型为 items,并使用 masterball 作为图标。

🛠 执行构建命令

  1. 在终端中输入以下命令以构建 hello_sapdon 项目:
    sapdon build hello_sapdon
  2. 构建完成后,您将在 hello_sapdon 文件夹下看到一个 dev 文件夹,其中包含构建好的 Addon 包。

生成优化后的 mcaddon 包文件

📚 学习资源

❓ 常见问题

如何更新框架版本?

npm update sapdon

如何添加依赖库?

build.config 中添加:

{
  "dependencies": [
    {
      "module_name": "@minecraft/server",
      "version": "1.8.0"
    }
  ]
}

🤝 社区支持

  • 官方 QQ 群:810904181

ts支持

quick start

编译 Sapdon

  1. 安装依赖:npm install
  2. 编译:npm run build
    1. 查看详细输出 npm run build -- verbose
    2. 保存中间文件夹 dist npm run build -- keep
    3. 你也可以组合两个参数 npm run build -- keep verbose