Skip to content
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

Refactor dark mode logic #875

Merged
merged 2 commits into from
Feb 2, 2024
Merged

Conversation

MinhxNguyen7
Copy link
Member

Summary

Implementing what I was trying to explain in #847 (comment). Only the second commit is relevant.

I believe that the code written here is much more readable and should be fully comprehensible within a minute of anyone reading. It's clear, minimally-nested, and well-named.

I know that this seems like a matter of pedantry, but it genuinely took me more than 5 minutes to understand what the logic was there. Someone might come along in the future to work on this code and be even more confused. Since you already understood how the logic works, it would've only taken you a few minutes to save us much more time (and perhaps even bugs) in the future.

If you don't understand what I'm getting at and why this is important, @ap0nia can explain it to you in person.

@MinhxNguyen7 MinhxNguyen7 self-assigned this Feb 1, 2024
Copy link
Contributor

@srukelman srukelman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see how this logic is so much clearer than what I wrote. Thank you.

@srukelman srukelman merged commit cc71fdc into deprecate-dark-mode Feb 2, 2024
5 of 7 checks passed
@EricPedley EricPedley deleted the deprecate-dark-mode-minh branch February 6, 2024 05:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants