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

@iki-inc/rack

v0.2.0

Published

You can copy the template files needed for web development into your own project.

Readme

Rack

リリースノート | 開発者用ドキュメント

WEB制作に必要なテンプレートファイルや制作環境を、自分のプロジェクトへ簡単に構築。
必要なライブラリも自動でインストール。

現在対応しているテンプレートや制作環境は以下の通り。

  • WEBサイト開発環境
    • Vite(提供している内容はこちらを参照)
  • 制作環境設定ファイルテンプレート(提供テンプレートはこちらを参照)
  • Pug(HTMLテンプレートエンジン)
  • Stylus(CSSプリプロセッサ)
  • TypeScript(独自ライブラリ)

テンプレート内容はtemplatesディレクトリから確認可能。

利用要件

Node.js v22.0.0 以上

Install

npm

npm i -g @iki-inc/rack

pnpm

pnpm add -g @iki-inc/rack

yarn

yarn global add @iki-inc/rack

Usage

利用方法は構築したいプロジェクトのディレクトリでrackコマンドを実行すると対話形式でテンプレートや環境を選択できる。

WEBサイト制作環境を構築する場合はプロジェクトルートで必ず実行が必要。
TypeScriptなどは直接コピーしたいディレクトリから実行することも可能で、プロジェクトルートで実行してもコピー先を指定することもできる。
※一部指定できないものもあり

rack

オプション

オプションを指定することで、必要なテンプレートや制作環境構築を直接実行できる。

ViteベースのWEBサイト開発環境を構築

rack --vite

Vite開発環境の提供している機能はこちらを参照。

制作環境設定ファイルテンプレートを構築

rack --env

提供しているテンプレートはこちらを参照。

Pugのアセット一式

rack --pug

Stylusのアセット一式

rack --stylus

TypeScriptのライブラリ選択

rack --ts

Rackのバージョン確認

rack --version

もしくは

rack -V
ヘルプ表示
rack --help

注意

npmサプライチェーン攻撃対策

ライブラリを自動でインストールする場合にはnpmサプライチェーン攻撃に対して少しでも対処するためにignore-scripts=trueを付与して実行しています。
そのため、インストールしたライブラリにpreスクリプトやpostスクリプトがあってもそれらは実行されません。
インストールされたライブラリの安全性を確認してnpm rebuild <パッケージ>を手動実行してください。
.npmrcignore-scripts=trueを記述している場合はnpm rebuild <パッケージ> --ignore-scripts=falseで一時的に解除可能です。

プロジェクトにインストールしているライブラリにpreスクリプトやpostスクリプトを調べるコマンドは下記を参考にしてください。

Tips

プロジェクトのpackage.jsonに下記のnpmスクリプトを追加しておくと便利です。

{
  "scripts": {
    "package:use-pre-or-post-scripts": "grep -r '\"install\"\\|\"preinstall\"\\|\"postinstall\"' node_modules/*/package.json | grep -v node_modules/node_modules",
    "package:rebuild": "npm_config_ignore_scripts=false npm rebuild ${npm_config_pkg:-} --loglevel=verbose",
    "rebuild-packages": "npm run package:rebuild --pkg=\"<パッケージ名> <パッケージ名>\""
  }
}

package:use-pre-or-post-scripts
プロジェクトにインストールしているライブラリにpreスクリプトやpostスクリプトが存在しているかチェックする。

package:rebuild
リビルドのショートカット。
npm run package:rebuild --pkg="<パッケージ> <パッケージ>"で実行。

rebuild-packages
インストールしているライブラリのバージョンが安全である場合はリビルドするパッケージを宣言しておくことで必要なライブラリを一括でリビルドできます。

grep -r '"install"\|"preinstall"\|"postinstall"' node_modules/*/package.json | grep -v node_modules/node_modules

コントリビューター向け

開発者は開発ドキュメントを参照。