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

aiagain-ui

v0.0.57

Published

A Component Library for Vue.js.

Readme

AiAgain-UI

npm i aiagain-ui -S

1.npm run dev

npm run bootstrap && npm run build:file && cross-env NODE_ENV=development webpack-dev-server --config build/webpack.demo.js & node build/bin/template.js
  1. 命令 npm run bootstrap 安装项目依赖, 初始化开发环境
  2. 命令 npm run build:file 构建网站相关文件
  3. 运行 webpack-dev-server 提供一个本地服务(serve) ,编译运行项目网站(打包规则配置 build/webpack.demo.js, 模式是development,入口文件是examples/entry.js)
  4. 执行 node build/bin/template.js 文件启动chokidar监听 examples/pages/template 目录下模板文件,若内容发生变化,执行命令 npm run i18n 重新生成网站文件
  5. webpack-dev-server 网站文件变更会重新编译加载

2.npm run dev:play

npm run build:file && cross-env NODE_ENV=development PLAY_ENV=true webpack-dev-server --config build/webpack.demo.js

该命令用于组件库开发中的功能展示 由于配置了如下环境变量NODE_ENV=development PLAY_ENV=true,可以在build/webpack.demo.js打包文件中看到入口文件examples/play.js, play.js 引用 examples/play/index.vue, 可以引入组件库任意组件用于功能展示。

3. npm run deploy:build

npm run build:file && cross-env NODE_ENV=production webpack --config    	build/webpack.demo.js && echo aiagain.eleme.io>>examples/aiagain-ui/CNAME

命令npm run build:file 构建网站相关文件 执行webpack --config build/webpack.demo.js 基于 production 模式,打包生成内容输出至examples/element-ui/目录下,将项目域名element.eleme.io写入 examples/element-ui/CNAME 文件中 主要用来生成组件文档

4. npm run dist

npm run clean && npm run build:file && npm run lint && webpack --config build/webpack.conf.js && webpack --config build/webpack.common.js && webpack --config build/webpack.component.js && npm run build:utils && npm run build:umd && npm run build:theme
  1. 命令npm run clean 清除打包/测试生成的目录及文件
  2. 命令npm run build:file 构建网站相关文件
  3. 命令npm run lint eslint代码检查;
  4. 打包webpack --config build/webpack.conf.js,入口文件 src/index.js 以 umd 格式输出到 lib/index.js;
  5. 打包webpack --config build/webpack.common.js,入口文件 src/index.js 以commonjs2格式输出到 lib/element-ui.common.js;
  6. 打包webpack --config build/webpack.component.js,入口文件 components.json,将packages目录下的组件,以commonjs2格式分别输出到lib目录,用于按需引入;
  7. 命令npm run build:utils 遍历 src/locale/lang 目录下所有JS文件,通过 babel 转译成 umd 格式,输出至 lib/umd/locale 目录下
  8. 命令npm run build:umd 把 src 目录下除了 src/index.js 文件外的其他文件通过 babel 转译后,输出至 lib 文件夹下
  9. 命令npm run build:theme 使用gulp构建主题样式,输出至 lib 文件夹下

npm发布组件包

配置 package.json 文件中属性值用于npm 发布

  • name: 包名,该名字是唯一的。需要去npm registry查看名字是否已被使用。
  • version: 包版本号,版本号规则参考《语义化版本 2.0.0》。每次发布至 npm 需要修改版本号,不能和历史版本号相同。
  • description: 包的描述,描述这个包的主要功能以及用途。
  • main: 入口文件,该字段需指向项目编译后的包文件。
  • keyword:关键字,数组、字符串。
  • author:包的作者。
  • private:是否私有,需要修改为 false 才能发布到 npm
  • license: 开源协议。
  • repository:包的Git Repo信息,包括type和URL。
  • homepage:项目官网的url。

npm 发布

首先 npmjs.com 上注册一个账号,确保 npm 使用的是原镜像。

npm config set registry http://registry.npmjs.org

然后在命令行窗口跳转至项目路径下, 运行 npm login 登录授权。

alt 属性文本

执行 npm publish 命令发布组件包。

alt 属性文本

发布成功后,进入组件包信息页面 https://www.npmjs.com/package/aiagain-ui, 可以看到上面的项目配置信息 。