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

aidoc

v0.0.4

Published

用于快速将注释直接转为文档站点,基于apidoc库,全部支持apidoc文档使用(但未完全展示全部参数结构),专属官方文档后续建设。

Readme

aidoc

[TOC]

用于快速将注释直接转为文档站点,基于apidoc库,全部支持apidoc文档使用(但未完全展示全部参数结构),专属官方文档后续建设。

目前正在快速完善中,如果 遇到问,可以issue反馈或回复邮件[[email protected]]。

感谢使用!

安装

全局安装后执行aidoc命令即可完成使用。

npm -g install aidoc

常用命令

aidoc -i ./src -w   	# 以监控模式运行,一般开发时使用

aidoc -i ./src 			# 编译输出文档

使用教程

使用简单,最多需要2步:

1.创建apidoc.json文件,指定项目及解析源码目录等被支持项(根据情况创建);

2.为方法书写aidoc注释;

步骤2中给出了常用示例,详细支持文档后续给出,初步可参考原(apidocjs.com)

步骤2:(API常用注释段示例)

/**
 * @api {Any} /module/controller/action 小标题
 * @apiGroup 用户认证
 * @apiName 登录认证
 * @apiVersion 0.0.1
 * @apiDescription 接收用户账号和密码进行登录认证,登录成功并返回access-token
 *
 * @apiBody {String}  [username] 用户账号/用户名
 * @apiBody {String}  [password] 用户密码
 *
 * @apiSuccess {Number} code    状态码,0:请求成功
 * @apiSuccess {String} message   提示信息
 * @apiSuccess {Object} [data]    返回数据
 *
 * @apiSuccessExample {json} Success-Response:
 * {"code":0,"message":"","data":[]}
 *
 * @apiErrorExample {json} Error-Response:
 * {"code":5001,"message":"接口异常"}
 */

步骤1:(apidoc.json示例)

较apidocjs新增‘首页配置’,暂时移除对header和footer的支持,但新增支持index.md(来配置首页)

{
  "name": "项目标题",
  "version": "0.3.0",
  "description": "文档描述",
  "title": "Custom AiDoc Title",
  "url" : "https://api.example.com",
  "sampleUrl": "https://apidoc.free.beeceptor.com",
  "output": "./apidoc-output",
  "input":["./"],
  "index": {
    "title": "首页内容-支持dumi的FrontMatter配置",
    "filename": "footer.md"
  },
  "order": [
    "User",
    "PostUser",
    "GetUser",
    "City",
    "Category (official)"
  ],
  "template": {
    "showRequiredLabels": false,
    "withCompare": true,
    "withGenerator": true,
    "aloneDisplay": false
  }
}

菜单排序专题