@lich-nhu-y/lunar
v0.4.0
Published
A JavaScript library for converting between solar and lunar dates, and for calculating the stems and branches of given dates
Downloads
30
Maintainers
Readme
@lich-nhu-y/lunar
A JavaScript library for converting between solar and lunar dates, and for calculating the stems and branches of given dates.
Installation
npm install @lich-nhu-y/lunar
yarn add @lich-nhu-y/lunar
Usage
Importing the Library
import {
solar2Lunar,
lunar2Solar,
getYearStem,
getYearBranch,
getYearStemBranch,
getMonthStem,
getMonthBranch,
getMonthStemBranch,
getDayStem,
getDayBranch,
getDayStemBranch,
getHourStem,
getHourBranch,
getHourStemBranch,
getDayType,
getLunarDayInfo,
} from '@lich-nhu-y/lunar';
Parameters:
date
:number
|string
- The solar date to convert.format
:moment.MomentFormatSpecification
(optional) - The format of the input date.
License
This project is licensed under the MIT License.
Made with create-react-native-library