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

jaweiwang-ui

v0.0.18

Published

要将组件库发布到npm,您需要遵循以下步骤:

Downloads

7

Readme

一个简单的自定义组件库

组件库发布到npm

要将组件库发布到npm,您需要遵循以下步骤:

创建或更新组件库的package.json文件。确保所有必要的字段都已正确填写,例如name、version、main等。

确保您的组件库可以通过npm安装和使用。

确保您有一个npm账户,如果没有,请在npm官网注册。

在命令行中登录到npm账户: 注意:登录前须要切换到官方源,否则不能登录

// 切换到官方镜像源
npm config set registry https://registry.npmjs.org/

npm login

输入您的用户名、密码和电子邮件地址。

确保您的组件库已准备好发布。如果是首次发布,可以使用:

npm publish

如果这是一个更新,请确保更新了package.json中的版本号,并使用:

npm publish --access public

如果您之前将访问权限设置为了restricted(默认设置)。

如果需要撤销发布,可以使用:

npm unpublish [package-name] --force

注意,这将从npm注册中心删除您的包,并且只能在72小时内执行。

确认发布成功,可以通过npm搜索查看您的包是否已经可用。

发布失败

1.清除npm缓存 有时候 npm 缓存中的一些文件可能会导致网络请求出错,这时我们可以尝试清除 npm 缓存。使用以下命令清除 npm 缓存:

npm cache clean --force

2.可能因为网络问题导致失败,试着切换网络

其他问题


报错:TypeError: Cannot read properties of null (reading 'isCE')
解决方法:不要把Vue本身打包进组件库代码