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

@klxin/pro-cli

v0.0.2

Published

@klxin/pro-cli

Readme

cli 脚手架简介

为什么要自己搞脚手架

  1. 在实际的开发过程中,我们经常用别人开发的脚手架,以节约搭建项目的时间。但是,当 npm 没有自己中意的脚手架时,我们不得不自己动手,此时学会开发前端 CLI 脚手架的技能就显得非常重要
  2. 根据交互动态生成项目结构和配置文件等
  3. 减少重复性的工作,不再需要复制其他项目再删除无关代码,或者从零创建一个项目和文件
  4. 多人协作更为方便,不需要把文件传来传去

入门需知

下面我们以创建 js 插件项目的脚手架来加深我们对前端脚手架的认知

chalk[1]       (控制台字符样式)
commander[2]   (实现 NodeJS 命令行)
download[3]    (实现文件远程下载)
fs-extra[4]    (增强的基础文件操作库)
handlebars[5]  (实现模板字符替换)
inquirer[6]    (实现命令行之间的交互)
log-symbols[7] (为各种日志级别提供着色符号)
ora[8]         (优雅终端 Spinner 等待动画)
update-notifier[9] (npm 在线检查更新)

功能说明

  1. init(初始化模板)
  2. template(下载模板)
  3. mirror(切换镜像)
  4. upgrade(检查更新)

目录结构

js-plugin-cli ├─ .gitignore ├─ .npmignore ├─ .prettierrc ├─ LICENSE ├─ README.md ├─ bin │ └─ index.js 入口文件 ├─ lib │ ├─ init.js 初始化 │ ├─ config.js 配置文件
│ ├─ download.js 下载/更新模板 │ ├─ mirror.js 切换镜像链接 │ └─ update.js 检查更新 └─ package.json