Comments (2)
A PrayerTimes object is only for a single day so a currentPrayer
would be none
if time for fajr has not yet begun because it does not know about the previous day's Isha. Similarly nextPrayer
would be none
if the time for isha has started since it doesn't know about tomorrow's fajr.
It is recommended to check for these values of none
and compute the previous or next day's prayer times to show the appropriate next or current prayer.
from adhan-js.
Also the currentPrayer and nextPrayer functions default to using the current date but you can also pass in a specific date for more advanced checks or for testing purposes.
from adhan-js.
Related Issues (20)
- Altitude Support HOT 1
- Prayer Ending Times HOT 1
- Moon Phases?
- Wrong time returned HOT 1
- [suggestion]: Use `const enums` for some constant variables
- time difference for asr on Turkey HOT 1
- The use of Temporal HOT 2
- [suggestion]: Add 'Imsak' Timings HOT 4
- Host the javascript on cdnjs or similar HOT 1
- Turkish Diyanet times for Netherlands gives wrong for yatsi time
- Reason for using sth like moment.js HOT 2
- Taking elevation into account for prayer times HOT 1
- Considering elevation for Salah times HOT 21
- TypeError: Cannot read properties of undefined (reading 'getTime') HOT 1
- add adjustment settings to sunset HOT 6
- Prayer times are wrong(?) HOT 16
- The possibility of adjusting the midnight time HOT 1
- Calculation is returning prayer times for next day instead of "today" HOT 3
- Getting Default Calculation Method for Location
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from adhan-js.