0.1.4 • Published 1 year ago

@lunisolar/plugin-fetalgod v0.1.4

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

@lunisolar/plugin-fetalgod

lunisolar.js胎神占方插件

lunisolar.js文档请进入lunisolar.js.org

安装:

npm install @lunisolar/plugin-fetalgod

使用:

查询胎神要先导入 fetalGod 插件,

之后可使用lunisolar().fetalGod 取得胎神描述,

也可以使用lunisolar().fetalGodData 取得胎神数据。

import lunisolar from 'lunisolar'
import { fetalGod } from '@lunisolar/plugin-fetalgod'

lunisolar.extend(fetalGod)

const lsr = lunisolar('2022-07-08')
lsr.fetalGod // 倉庫棲外東南
lsr.fetalGodData.stemPlace // 倉庫
lsr.fetalGodData.branchPlace // 雞棲
lsr.fetalGodData.direction // 外東南
lsr.fetalGodData.description // 倉庫棲外東南

fetalGodData 包含以下属性

属性描述返回类型
stemPlace根据天干推算的胎神位置,有以下五种: '門', '碓磨', '廚灶', '倉庫', '房床'string
branchPlace根据地支推算的胎神位置,有以下六种:'碓', '廁', '爐', '門', '雞棲', '床'string
direction胎神的方向,如'外东南'、'外西'、'内中' 等string
directionValue返回方位对应的九宫数,外为正,内为负number
description胎神占方的完整描述,如:"占門碓外東南"string
0.1.4

1 year ago

0.1.2

1 year ago

0.1.3

1 year ago

0.1.1

1 year ago

0.1.0

1 year ago

0.0.1

1 year ago