Skip to content

Conversation

@arikorn
Copy link
Contributor

@arikorn arikorn commented Feb 2, 2026

Since ts-check is enabled for this file, numerous errors are reported when it is opened in VS Code.

For the most part this PR just adds the necessary JSDoc comments. In a few cases it fixes minor coding errors revealed by the type-checking.

Summary by CodeRabbit

  • Chores
    • Improved application stability through enhanced safety checks and type clarity.

Since `ts-check` is enabled for this file, numerous errors are reported when it is opened in VS Code.

For the most part this PR just adds the necessary JSDoc comments. In a few cases it fixes minor coding errors revealed by the type-checking.
@coderabbitai
Copy link

coderabbitai bot commented Feb 2, 2026

📝 Walkthrough

Walkthrough

Enhanced type safety in launcher/main.js through JSDoc annotations and null-safety checks, including optional chaining for IPC communication. Added customLog function for dual-stream logging. Made shouldRestart field public in RespawnMonitor for launcher integration.

Changes

Cohort / File(s) Summary
Type Safety & Logging Enhancements
launcher/main.js
Added JSDoc type annotations throughout, introduced optional chaining for child IPC access, guarded crashTimeout clearing, implemented customLog function for simultaneous logStream and console output.
Public API Expansion
shared-lib/lib/Respawn.ts
Changed shouldRestart field from private to public visibility to enable external access from launcher/main.js, maintaining boolean type.

Poem

🛡️ With optional chains and guards so tight,
Null checks dancing in the night,
shouldRestart now steps into the light,
Types and logs align just right,
Safety blooms in TypeScript's flight! ✨

🚥 Pre-merge checks | ✅ 2
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the main objective of the pull request—fixing type errors in launcher/main.js through JSDoc annotations and minor code fixes.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@Julusian Julusian merged commit b636c05 into bitfocus:main Feb 2, 2026
8 checks passed
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