infra: cleanup tsconfig and add typecheck to desktop #253

Merged
talksik merged 1 commits from add-typecheck into main 2026-06-09 17:47:48 +00:00
talksik commented 2026-06-09 17:43:41 +00:00 (Migrated from github.com)

Summary by CodeRabbit

  • Chores
    • Updated TypeScript configuration for improved module resolution and compilation settings.
    • Enhanced CI/CD quality gate workflow with additional type-checking step for desktop builds.
    • Updated build script configuration for type-checking processes.
<!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Chores** * Updated TypeScript configuration for improved module resolution and compilation settings. * Enhanced CI/CD quality gate workflow with additional type-checking step for desktop builds. * Updated build script configuration for type-checking processes. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
coderabbitai[bot] commented 2026-06-09 17:43:55 +00:00 (Migrated from github.com)

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 65216441-ec00-4771-9e62-aed159801632

📥 Commits

Reviewing files that changed from the base of the PR and between 92894c4af8 and 10c2fbe65f.

📒 Files selected for processing (4)
  • .github/workflows/pr-quality-gate-js.yml
  • js/desktop/forge.config.ts
  • js/desktop/package.json
  • js/desktop/tsconfig.json

📝 Walkthrough

Walkthrough

The PR updates the TypeScript configuration to use ESNext modules and bundler resolution strategy, replaces the compile npm script with a typecheck script, updates forge.config.ts to remove an unused type import and work with the new configuration, and adds a yarn typecheck step to the desktop workflow.

Changes

TypeScript Typecheck Integration

Layer / File(s) Summary
TypeScript compiler configuration
js/desktop/tsconfig.json
Module system changed from commonjs to ESNext and moduleResolution changed from node to bundler.
Typecheck script and forge config cleanup
js/desktop/package.json, js/desktop/forge.config.ts
The compile script is replaced with typecheck that runs tsc --noEmit; the unused SignToolOptions import is removed from forge config and hashes is cast to any type.
Workflow typecheck step
.github/workflows/pr-quality-gate-js.yml
The desktop job adds a "Typecheck" step that runs yarn typecheck after dependency installation.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

A typecheck hop in TypeScript's way,
ESNext bounds and bundler's play,
The workflow guards with zealous care,
While forge trims fat from config's air. ✨🐰

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main changes: adding a typecheck step to the workflow and cleaning up the tsconfig with module/moduleResolution updates.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

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

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch add-typecheck

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

<!-- This is an auto-generated comment: summarize by coderabbit.ai --> <!-- review_stack_entry_start --> [![Review Change Stack](https://storage.googleapis.com/coderabbit_public_assets/review-stack-in-coderabbit-ui.svg)](https://app.coderabbit.ai/change-stack/flowy-live/llink/pull/253?utm_source=github_walkthrough&utm_medium=github&utm_campaign=change_stack) <!-- review_stack_entry_end --> No actionable comments were generated in the recent review. 🎉 <details> <summary>ℹ️ Recent review info</summary> <details> <summary>⚙️ Run configuration</summary> **Configuration used**: defaults **Review profile**: CHILL **Plan**: Pro Plus **Run ID**: `65216441-ec00-4771-9e62-aed159801632` </details> <details> <summary>📥 Commits</summary> Reviewing files that changed from the base of the PR and between 92894c4af88fa3bfec278193417cd0da93b89942 and 10c2fbe65f5e904b7f7f77f5dede1e29dbabcea1. </details> <details> <summary>📒 Files selected for processing (4)</summary> * `.github/workflows/pr-quality-gate-js.yml` * `js/desktop/forge.config.ts` * `js/desktop/package.json` * `js/desktop/tsconfig.json` </details> </details> --- <!-- walkthrough_start --> <details> <summary>📝 Walkthrough</summary> ## Walkthrough The PR updates the TypeScript configuration to use ESNext modules and bundler resolution strategy, replaces the `compile` npm script with a `typecheck` script, updates `forge.config.ts` to remove an unused type import and work with the new configuration, and adds a `yarn typecheck` step to the desktop workflow. ## Changes **TypeScript Typecheck Integration** | Layer / File(s) | Summary | |---|---| | **TypeScript compiler configuration** <br> `js/desktop/tsconfig.json` | Module system changed from `commonjs` to `ESNext` and moduleResolution changed from `node` to `bundler`. | | **Typecheck script and forge config cleanup** <br> `js/desktop/package.json`, `js/desktop/forge.config.ts` | The `compile` script is replaced with `typecheck` that runs `tsc --noEmit`; the unused `SignToolOptions` import is removed from forge config and `hashes` is cast to `any` type. | | **Workflow typecheck step** <br> `.github/workflows/pr-quality-gate-js.yml` | The desktop job adds a "Typecheck" step that runs `yarn typecheck` after dependency installation. | ## Estimated code review effort 🎯 2 (Simple) | ⏱️ ~10 minutes ## Poem > A typecheck hop in TypeScript's way, > ESNext bounds and bundler's play, > The workflow guards with zealous care, > While forge trims fat from config's air. ✨🐰 </details> <!-- walkthrough_end --> <!-- pre_merge_checks_walkthrough_start --> <details> <summary>🚥 Pre-merge checks | ✅ 5</summary> <details> <summary>✅ Passed checks (5 passed)</summary> | Check name | Status | Explanation | | :------------------------: | :------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------- | | Description Check | ✅ Passed | Check skipped - CodeRabbit’s high-level summary is enabled. | | Title check | ✅ Passed | The title accurately summarizes the main changes: adding a typecheck step to the workflow and cleaning up the tsconfig with module/moduleResolution updates. | | Docstring Coverage | ✅ Passed | No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. | | Linked Issues check | ✅ Passed | Check skipped because no linked issues were found for this pull request. | | Out of Scope Changes check | ✅ Passed | Check skipped because no linked issues were found for this pull request. | </details> <sub>✏️ Tip: You can configure your own custom pre-merge checks in the settings.</sub> </details> <!-- pre_merge_checks_walkthrough_end --> <!-- finishing_touch_checkbox_start --> <details> <summary>✨ Finishing Touches</summary> <details> <summary>📝 Generate docstrings</summary> - [ ] <!-- {"checkboxId": "7962f53c-55bc-4827-bfbf-6a18da830691"} --> Create stacked PR - [ ] <!-- {"checkboxId": "3e1879ae-f29b-4d0d-8e06-d12b7ba33d98"} --> Commit on current branch </details> <details> <summary>🧪 Generate unit tests (beta)</summary> - [ ] <!-- {"checkboxId": "f47ac10b-58cc-4372-a567-0e02b2c3d479", "radioGroupId": "utg-output-choice-group-unknown_comment_id"} --> Create PR with unit tests - [ ] <!-- {"checkboxId": "6ba7b810-9dad-11d1-80b4-00c04fd430c8", "radioGroupId": "utg-output-choice-group-unknown_comment_id"} --> Commit unit tests in branch `add-typecheck` </details> </details> <!-- finishing_touch_checkbox_end --> <!-- tips_start --> --- <sub>Comment `@coderabbitai help` to get the list of available commands and usage tips.</sub> <!-- tips_end --> <!-- internal state start --> <!-- DwQgtGAEAqAWCWBnSTIEMB26CuAXA9mAOYCmGJATmriQCaQDG+Ats2bgFyQAOFk+AIwBWJBrngA3EsgEBPRvlqU0AgfFwA6NPEgQAfACgjoCEejqANiS7wMAMypcGVzNm6RciJvfhF0GejRaelxZblFYUQBrD3xIJUQogm4DADlsZgFKLgAmAFYAZgMAVQAlABkuWFxcbkQOAHoGonVYbAENJmYGuwt8AHdZMAtJEgaLEYwohu5sCYb8ouLEbI80CyjEeCiDAGV8bAoGEkgBKgwGWC4g2jBQ8Mvog2g0ClJcU/PLrmZtDD3cNRsPV+OF/qUSBJ4CR+pQQQZyioSBZ4QBhCgkah0dCcSA5AAMOQAbGB8ST8QBOaAARgA7BwACwFRnUgBaRn0xnAUDI9HwdhwBGIZGUNHoXTYGFxvH4wlE4ikMnkTCUVFU6i0Ok5JigcFQqEwgsIpHIVDFClY7C4VH6kEQGV+FHkcgUqpUak02l0YEMXNMBg0LVwbQEDX6+AoUV6A0QMwoYAAjth1uohkQsWAhIgNLJmBYOAYAETFgwAYlLkAAggBJYWmrH0e2sV7yfmMWCYUiIMyReLSJL4dwABVKkCTKdCkHTNEg4cj0dtGAGKAuFmwCX86GC6ng+Aw60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