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

@suzukihayate/jp-holidays

v0.1.0

Published

日本の祝日を計算で求める依存ゼロのライブラリ。春分・秋分、ハッピーマンデー、振替休日、国民の休日、五輪特例に対応。

Readme

jp-holidays

日本の祝日を計算で求める、依存ゼロのライブラリです。祝日のデータファイルを毎年更新する必要がありません。

  • 固定日・ハッピーマンデー(成人の日・海の日・敬老の日・スポーツの日)
  • 春分の日・秋分の日(天文近似式)
  • 振替休日(祝日が日曜のとき)・国民の休日(祝日に挟まれた平日)
  • 五輪特例(2020/2021 の海の日・スポーツの日・山の日の移動)
  • 依存ゼロ・型定義つき・ESM をそのまま import

対応範囲:1980〜2099 年(春分・秋分の近似式が有効な範囲)。

インストール

npm install @suzukihayate/jp-holidays

使い方

import { holidays, isHoliday, holidayName } from '@suzukihayate/jp-holidays';

holidays(2024);
// [ { date: 2024-01-01, name: '元日' },
//   { date: 2024-01-08, name: '成人の日' }, ... 振替休日も含む ]

isHoliday('2024-05-03');   // true
isHoliday('2024-06-02');   // false
holidayName('2024-05-06'); // "振替休日"

API

  • holidays(year) — その年の祝日を { date, name }[](日付順)で返す
  • isHoliday(input)Date / "YYYY-MM-DD" が祝日か
  • holidayName(input) — 祝日名(祝日でなければ null

正確性

2024 年の全祝日(振替休日含む)、2020 年の五輪特例、国民の休日などをテストで検証しています(node --test)。春分・秋分は 1980〜2099 年で官報の確定日と一致する近似式を使用しています。

License

MIT © 2026 Hayate Suzuki