const moon = require('the-moon');
Get today's moon
moon(); // đ (today's moon)
Choose a different date
moon(2017); // đ (today in 2017)
moon(2017, 3, 14); // đ (a specific date)
Choose from available formats (moon.FORMATS) default is icon
moon(2017, 3, 14, {format: 'code'}); // 'full-moon'
moon({format: 'name'}); // 'Last Quarter Moon'
| format | example |
|---|---|
| icon | đ |
| code | full |
| name | Full Moon |
| Icon | Name | Code |
|---|---|---|
| đ | New Moon | new |
| đ | Waxing Crescent Moon | waxing-crescent |
| đ | Quarter Moon | quarter |
| đ | Waxing Gibbous Moon | waxing-gibbous |
| đ | Full Moon | full |
| đ | Waning Gibbous Moon | waning-gibbous |
| đ | Last Quarter Moon | last-quarter |
| đ | Waning Crescent Moon | waning-crescent |

npx the-moon