-
-
Notifications
You must be signed in to change notification settings - Fork 166
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 GUI bugs #707
Fix GUI bugs #707
Conversation
gui/src/App.tsx
Outdated
).then((res) => res.json()); | ||
) | ||
.then((res) => res.json()) | ||
.then((json: Release[]) => json.filter((rl) => !rl.prerelease)); |
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.
It'd be smart if we were to actually validate the objects here, for example with zod
.
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.
validated :p
document.addEventListener('keypress', onKeyboard); | ||
return () => document.removeEventListener('keypress', onKeyboard); | ||
document.addEventListener('keyup', onKeyboard); | ||
return () => document.removeEventListener('keyup', onKeyboard); |
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.
Please just move this into a different PR...
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.
makes 4 branches
).then((res) => res.json()); | ||
) | ||
.then((res) => res.json()) | ||
.then((json: any[]) => json.filter((rl) => rl?.prerelease === false)); |
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.
no.
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.
its better than bringing a whole dependency for one type check
__VERSION_TAG__ && | ||
typeof releases[0].tag_name === 'string' && | ||
semver.gt(releases[0].tag_name, __VERSION_TAG__) |
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.
very cursed, no thank you.
curIndex
before