A JavaScript library for converting between solar and lunar dates, and for calculating the stems and branches of given dates.
npm install @lich-nhu-y/lunar
yarn add @lich-nhu-y/lunar
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.
-
This project is licensed under the MIT License.
Made with create-react-native-library