1.0.2 • Published 9 months ago

sandhya-js v1.0.2

Weekly downloads
-
License
-
Repository
github
Last release
9 months ago

SandhyaJS

SandhyaJS is a tiny BSD-licensed JavaScript library for calculating sandhya time for chanting gayatri, created by Oleksandr Popov (@popovoleksandr).

Usage example

const { DateTime, Interval} = require("luxon");

const date = DateTime.fromObject({
    year: 2023,
    month: 7,
    day: 1,
    hour: 0
}, {zone: 'UTC+5:30'});

const lat = 23.423201, 
      lng = 88.388268;

// get Gayatri sandhya information
var gayatri = SandhyaCalc.calculateGayatriSandhyaTime(date, lat, lng);

// get Savitri sandhya information
const savitri = SandhyaCalc.calculateSavitriSandhyaTime(date, lat, lng);

// get Saraswati sandhya information
const saraswati = SandhyaCalc.calculateSaraswatiSandhyaTime(date, lat, lng);

// get all sandhya information
const all = SandhyaCalc.calculateAllSandhyaTimes(date, lat, lng);

SandhyaJS is also available as an NPM package:

$ npm install sandhya-js
var SandhyaCalc = require('sandhya-js');

Changelog

1.0.2 Aug 04, 2023

  • Fixed typos
  • Added all sandhyas calculation

1.0.1 Aug 04, 2023

  • Added Eslint
  • Added CI to push to NPM
  • Published to NPM.

1.0.0 Aug 03, 2023

  • First implementation with tests