New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

jewish-holidays

Package Overview
Dependencies
Maintainers
0
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jewish-holidays

Jewish holidays

  • 1.1.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
9
decreased by-92.97%
Maintainers
0
Weekly downloads
 
Created
Source

Jewish Holidays

An easy-to-use npm package for checking Jewish holidays and Shabbat.

npm version License Build Status Code Coverage

## Installation

To install the package, run one of the following commands:

npm i jewish-holidays

or with yarn

yarn add jewish-holidays

Usage

You can use the package in your JavaScript projects as shown below:

import { isYomTov, isShabbat } from 'jewish-holidays';

// Check if a date is Yom Tov
const date = new Date();
const isInChutzLaaretz = true; // Adjust as needed
console.log(isYomTov(date, isInChutzLaaretz)); // true or false

// Check if a date is Shabbat
console.log(isShabbat(date)); // true or false

Functions

isYomTov

isYomTov(date: Date | BasicJewishDate, isChutzLaaretz: boolean) => boolean

Determines if the given date is a Yom Tov (Jewish holiday).

  • date: A JavaScript Date object or a BasicJewishDate object.
  • isChutzLaaretz: A boolean indicating if the calculation should consider diaspora holidays.

isShabbat

isShabbat(date: Date | BasicJewishDate) => boolean

Determines if the given date is Shabbat.

  • date: A JavaScript Date object or a BasicJewishDate object.

Click for more
export declare const isErevShabbat: (date: Date | BasicJewishDate) => boolean;

export declare const isErevYomTov: (date: Date | BasicJewishDate) => boolean;

export declare const isCholHaMoed: (date: Date | BasicJewishDate, isChutzLaaretz?: boolean) => boolean;

export declare const isChanukah: (date: Date | BasicJewishDate) => boolean;

License

MIT

Keywords

FAQs

Package last updated on 25 Jan 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc