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

@ddj-v2/ui-setting

v1.2.1

Published

ddj-v2 powered by https://github.com/hydro-dev/Hydro

Readme

ddj-v2-ui-setting

ddj-v2 powered by https://github.com/hydro-dev/Hydro

第一次 publish

npm login
npm publish --access public
# 建立對應 npm 現有版本的 Tag
git tag v1.0.0
# 推送到遠端
git push origin v1.0.0

addon 設定

  1. 安裝 CI/CD 所需套件
npm install -D semantic-release \
@semantic-release/commit-analyzer \
@semantic-release/release-notes-generator \
@semantic-release/github \
@semantic-release/npm
  1. 建立設定 .releaserc
{
  "branches": ["main"],
  "plugins": [
    "@semantic-release/commit-analyzer",
    "@semantic-release/release-notes-generator",
    "@semantic-release/npm",
    "@semantic-release/github"
  ]
}

.npmignore

# 排除所有隱藏檔案與資料夾
.*
!/.npmignore

# 排除 CI 與開發工具設定
.github/
.vscode/
node_modules/
*.log

# 排除測試與原始碼 (如果你的 build 結果在 dist/ 或 lib/)
test/
tests/
src/
__tests__/
jest.config.js
tsconfig.json

# 排除 semantic-release 可能產生的檔案
release.config.js
.releaserc

.gitignore

# 依賴套件 (絕對不能進 Git)
node_modules/
/npm-debug.log*
/yarn-error.log*

# 編譯產物 (建議不進 Git,由 CI 在發佈時產生)
dist/
lib/
build/

# 測試與覆蓋率報告
coverage/
*.lcov
.nyc_output/

# 敏感資訊 (雖然你現在用 Trusted Publisher 不需要 NPM_TOKEN,但還是要防範)
.env
.env.local
.secret
*.pem

# 系統檔案
.DS_Store
Thumbs.db

# semantic-release 暫存檔 (如果有用到的話)
package-lock.json.bak
  1. github action .github/workflows/publish.yml
name: Release

on:
  push:
    branches:
      - main

jobs:
  release:
    runs-on: ubuntu-latest
    permissions:
      contents: write    # 寫入 Git 標籤與 Release
      issues: write      # 讓 semantic-release 在 Issue 留言
      pull-requests: write
      id-token: write    # 關鍵:啟用 OIDC Trusted Publishing
    steps:
      - uses: actions/checkout@v4

      - uses: actions/setup-node@v4
        with:
          node-version: '24'
          # Required so npm CLI targets the correct registry and can perform OIDC auth
          registry-url: 'https://registry.npmjs.org'
      - run: npm install -g npm@latest # 點睛之筆 更新 npm 版本 github action 預設的 npm 版本過舊 會導致 publish 失敗 我被坑了好久
      - run: npm install
      - run: npm ci
      - run: npx semantic-release
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

npm 設定

https://docs.npmjs.com/trusted-publishers 參考

記得package.json要有

  "repository": {
    "type": "git",
    "url": "https://github.com/Fudan-Computer-Science/ddj-v2-ui-setting.git"
  }