-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: only one of today's and tomorrow's prayerCard is highlighted #8
Conversation
@@ -20,6 +20,7 @@ module.exports = { | |||
], | |||
rules: { | |||
'react/jsx-uses-react': 'off', | |||
'react/react-in-jsx-scope': 'off' | |||
'react/react-in-jsx-scope': 'off', | |||
'@typescript-eslint/no-explicit-any': 'off' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why disable any check?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So i can create my beautiful baby Fixtype
@@ -0,0 +1 @@ | |||
export type FixType = any; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
L7ob
nextPrayerToday ? todayPrayerTimes[nextPrayerToday] : tomorrowPrayerTimes[nextPrayerTomorrow] | ||
) as Date; | ||
let nextPrayer = nextPrayerToday; | ||
let nextPrayerTime: FixType = nextPrayerToday ? todayPrayerTimes[nextPrayerToday] : null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use keyof adhan.PrayerTimes | null
instead of FixType
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Already tested :)
Type 'Coordinates' is not assignable to type 'keyof PrayerTimes | null'.ts(2322)
I "any" it for now because no time for it, otherwise i'll take a close look at it asap.
Fixed in a separate commits. Thank you for your contribution! |
@all-contributors please add @smehdii for code and ideas |
I've put up a pull request to add @smehdii! 🎉 |
fix #2