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

@dt-frames/cli

v4.0.1

Published

用于快速拉取模板、初始化**组件库 / 前端工程**脚手架的命令行工具(`dt-cli`)。

Readme

@dt-frames/cli

用于快速拉取模板、初始化组件库 / 前端工程脚手架的命令行工具(dt-cli)。

环境要求

  • Node.js>= 18.2.0(与 package.jsonengines.node 一致)

安装 CLI

使用官方包名安装

npm install -g @dt-frames/cli
# 或
pnpm add -g @dt-frames/cli

安装后全局命令为 dt-cli(由本包 package.jsonbin 字段决定)。

安装时使用自定义包名(npm 别名)

若希望在本地 node_modules / 锁文件里使用你自己起的包名(例如 my-company-cli),但仍安装同一套代码,可使用 npm 的别名语法:

npm install -g my-company-cli@npm:@dt-frames/cli

说明:

  • my-company-cli 为你自定义的名称,需符合 npm 包名规则。
  • 全局可执行命令仍为发布包中配置的 dt-cli;若需要不同的命令名,需 fork 后修改本仓库 package.json 里的 bin 再自行发布。

本地开发(链接到全局)

cd /path/to/this/cli/package
pnpm install
pnpm link --global

之后在任意目录可直接执行 dt-cli

使用说明

查看版本与帮助

dt-cli --version
dt-cli --help
dt-cli create --help

直接执行 dt-cli(不带子命令)会输出帮助与 banner。

创建项目

# 指定目录名 / 项目名
dt-cli create my-ui-lib

# 不传名称:进入交互式输入项目名称
dt-cli create

# 目录名与 package.json 的 name 不一致时(例如作用域包)
dt-cli create my-ui-lib --package-name @my-scope/my-ui-lib

# 目标目录已存在时强制覆盖
dt-cli create my-ui-lib -f

生成完成后,按终端提示进入目录并安装依赖、启动开发服务(具体以模板仓库说明为准)。

其他选项(create)

| 选项 | 说明 | |------|------| | -f, --force | 若目标目录已存在则直接删除后重建 | | -c, --clone | 拉取远程模板时使用 git clone(传给下载器) | | -x, --proxy <proxyUrl> | 设置 HTTP_PROXY 以下载模板 | | -p, --package-name <name> | 写入生成项目 package.jsonname 字段;默认与项目目录名相同 |

开发与测试

pnpm install
pnpm test

pnpm test 会执行 CLI 的帮助命令,用于快速校验入口脚本与 Commander 配置是否正常。

模板来源

默认从 Gitee 模板仓库拉取(见 lib/creator.js 中的地址)。若需更换模板,可修改该文件中的仓库 URL 与分支。

许可证

MIT