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

Imports, Exports, Types, and Style #9

Merged
merged 5 commits into from
Jan 9, 2024
Merged

Imports, Exports, Types, and Style #9

merged 5 commits into from
Jan 9, 2024

Conversation

lishaduck
Copy link
Member

I botched up merging #7.

I figured out how to type-annotate Preact functions, so I murdered the lamdas!
Hooray for genocide!*

* Genocide is terrible.
  The atrocious acts by
  - the Russians in Ukraine,
  - the Nazis in the Holocaust,
  - and  many others, like in Somalia and Vietnam,
  are not to be tolerated at any cost, lest history repeat itself.
  In lighter topics, back to vanquishing poor coding style!
Now that these interfaces are exposed, they should have good types.
Also, I asked copilot to simplify a bit of logic in the header to make up for the added complexity.
In addition, I more consistently used optional properties over undefined types.
Simplify code in a manner after God's own heart.
Or maybe just mine.
This fixes a lot of type holes.
We now use template literal types, custom type literal functions, and don't use casts.
In addition, a lot more things are `readonly` or `const` now. Down with mutability!

UI-wise, I removed the link to the homepage in the header, because you can just click the "logo."
This simplifies quite a bit of code.
@lishaduck lishaduck added the documentation Improvements or additions to documentation label Jan 9, 2024
@lishaduck lishaduck self-assigned this Jan 9, 2024
@lishaduck lishaduck requested review from MattsAttack, iiAzui and a team as code owners January 9, 2024 18:25
@lishaduck lishaduck merged commit 2bcab3b into main Jan 9, 2024
4 checks passed
@lishaduck lishaduck deleted the imports-n-exports branch January 9, 2024 18:32
@lishaduck lishaduck added this to the State milestone May 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant