🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

@kabeep/zodiac-animals

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@kabeep/zodiac-animals

A JavaScript zodiac animals utility library

latest
Source
npmnpm
Version
1.0.3
Version published
Weekly downloads
4
-80%
Maintainers
1
Weekly downloads
 
Created
Source

zodiac-animals

🐼 A JavaScript zodiac animals utility library

NodeJS License NPM Codecov Codacy Badge CircleCI

English | 简体中文

Insights

📖 Introduction

Considering tree-shaking and the rigor required due to cultural differences, the output will exclude i18n content.

A lite utility library using Lunar Calendar.

See documentation.

⚙️ Installation

npm install @kabeep/zodiac-animals --save
yarn add @kabeep/zodiac-animals
pnpm add @kabeep/zodiac-animals

🚀 Usage

CommonJS

const { ANIMALS, zodiac, Zodiac: IZodiac } = require('@kabeep/zodiac-animals');

ESModule

import { ANIMALS, zodiac, type Zodiac } from '@kabeep/zodiac-animals';

Methods: zodiac(date)

zodiac(new Date()) as Zodiac;
ParameterTypeOptionalDefaultDescription
dateDateNo-Date Object of Gregorian Calendar

Returns: interface Zodiac

Result Object:

KeyTypeRequiredDescription
namestringtrueZodiac Animal Name
matestring[]trueZodiac Animal Mates
traitsstring[]trueZodiac Animal Traits
aliasstringfalseZodiac Animal i18n Alias
yearnumbertrueLunar Year of Date Input
monthnumbertrueLunar Month of Date Input
daynumbertrueLunar Day of Date Input
isLeapMonthbooleantrueLunar Leap Month Flag of Date Input
fromDatetrueGregorian Date of the First Day of the Lunar Year (Return an Invalid Date if an Exception Occurs)
toDatetrueGregorian Date of the Last Day of the Lunar Year (Return an Invalid Date if an Exception Occurs)
  • lunar-date-fns - 🗓️ A JavaScript lunar date utility library.
  • lunar-birthday-cli - 🎂 A Node.js Library to list the lunar birthday in terminal.

🏅 Credits

  • zodiacAnimals2 - Reference is made to data design of this repository.

🤝 Contribution

Contributions via Pull Requests or Issues are welcome.

📄 License

This project is licensed under the MIT License. See the LICENSE file for details.

Keywords

zodiac

FAQs

Package last updated on 29 Nov 2024

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