Skip to content

chore(front): remove vite-plugin-checker background TS/ESLint checks#18437

Merged
charlesBochet merged 1 commit intomainfrom
charles-remove-vite-plugin-checker
Mar 5, 2026
Merged

chore(front): remove vite-plugin-checker background TS/ESLint checks#18437
charlesBochet merged 1 commit intomainfrom
charles-remove-vite-plugin-checker

Conversation

@charlesBochet
Copy link
Copy Markdown
Member

@charlesBochet charlesBochet commented Mar 5, 2026

Summary

Removes vite-plugin-checker and all references to VITE_DISABLE_TYPESCRIPT_CHECKER / VITE_DISABLE_ESLINT_CHECKER.

These background checks are no longer needed because our dev experience now relies on independent linters and type-checkers:

  • npx nx lint:diff-with-main twenty-front for ESLint
  • npx nx typecheck twenty-front for TypeScript

Running these as separate processes (rather than inside Vite) is faster, gives cleaner output, and avoids the significant memory overhead that vite-plugin-checker introduces during vite dev and vite build. The old env vars to disable them are removed from vite.config.ts, package.json scripts, nx.json, .env.example, and all translated docs.

Background TypeScript and ESLint checks via vite-plugin-checker are no
longer needed. Our dev experience now relies on independent linters and
type-checkers (npx nx lint and npx nx typecheck) that run separately from
the Vite build process, making the in-process checker redundant and an
unnecessary memory overhead.

Made-with: Cursor
Copilot AI review requested due to automatic review settings March 5, 2026 17:34
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

No issues found across 18 files

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps bot commented Mar 5, 2026

Greptile Summary

This PR removes vite-plugin-checker and all related configuration (VITE_DISABLE_TYPESCRIPT_CHECKER, VITE_DISABLE_ESLINT_CHECKER) from twenty-front, replacing in-Vite background checks with dedicated nx lint:diff-with-main and nx typecheck commands run as separate processes. All 14 translated troubleshooting docs are updated accordingly.

Key changes:

  • vite.config.ts: Removes the checker import and plugin call, the VITE_DISABLE_TYPESCRIPT_CHECKER env var handling, and the isBuildCommand/tsConfigPath logic that selected tsconfig.build.json vs tsconfig.json — no longer needed since type checking is done externally. The eslint-disable is now correctly scoped inline to the single console.log statement instead of file-level.
  • package.json & nx.json: Build scripts and storybook configuration cleaned up by removing the now-obsolete VITE_DISABLE_TYPESCRIPT_CHECKER=true env var injections.
  • Docs (EN + 13 translations): The OOM memory troubleshooting section removes the checker disable workaround as a first step; the remaining guidance ("Run only needed services") flows correctly.
  • Note: packages/twenty-ui retains its own vite-plugin-checker usage, and the related troubleshooting reference in the docs is correctly left in place.

This is a clean removal with no runtime impact on the application—all type checking and linting is preserved via independent nx tasks.

Confidence Score: 5/5

  • This PR is safe to merge—it is a clean removal of an optional dev-tooling plugin with no runtime impact.
  • All changes are purely in build tooling and documentation. The runtime application is unaffected. TypeScript and ESLint checking is preserved via independent nx tasks. No remaining references to the removed env vars exist in the codebase, and twenty-ui's use of vite-plugin-checker is correctly left untouched.
  • No files require special attention.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    subgraph Before["Before this PR"]
        B_Dev["vite dev / vite build"]
        B_Checker["vite-plugin-checker<br/>(TS + ESLint in-process)"]
        B_Env["VITE_DISABLE_TYPESCRIPT_CHECKER=true<br/>(escape hatch)"]
        B_Dev --> B_Checker
        B_Env -. disables .-> B_Checker
    end

    subgraph After["After this PR"]
        A_Dev["vite dev / vite build<br/>(no checker plugin)"]
        A_TS["npx nx typecheck twenty-front<br/>(separate process)"]
        A_Lint["npx nx lint:diff-with-main twenty-front<br/>(separate process)"]
        A_Dev
        A_TS
        A_Lint
    end

    Before -->|"PR removes checker,<br/>env var, escape hatch"| After
Loading

Last reviewed commit: 3d8697c

@charlesBochet charlesBochet merged commit 1affa1e into main Mar 5, 2026
49 of 51 checks passed
@charlesBochet charlesBochet deleted the charles-remove-vite-plugin-checker branch March 5, 2026 17:55
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Removes vite-plugin-checker and the associated Vite env-var toggles, shifting type-checking and linting to separate Nx tasks to improve dev/build performance and reduce memory overhead.

Changes:

  • Removed vite-plugin-checker usage from packages/twenty-front/vite.config.ts and dropped VITE_DISABLE_TYPESCRIPT_CHECKER support.
  • Cleaned up related build/storybook commands and removed vite-plugin-checker from devDependencies.
  • Removed now-obsolete troubleshooting guidance across the main docs and translations.

Reviewed changes

Copilot reviewed 18 out of 18 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
packages/twenty-front/vite.config.ts Removes checker plugin wiring and related env-var logic.
packages/twenty-front/package.json Updates build scripts and drops vite-plugin-checker dependency.
packages/twenty-front/.env.example Removes the deprecated env-var example.
packages/twenty-docs/developers/self-host/capabilities/troubleshooting.mdx Removes outdated advice for disabling Vite background checks.
packages/twenty-docs/l/ar/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (AR).
packages/twenty-docs/l/cs/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (CS).
packages/twenty-docs/l/de/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (DE).
packages/twenty-docs/l/es/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (ES).
packages/twenty-docs/l/fr/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (FR).
packages/twenty-docs/l/it/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (IT).
packages/twenty-docs/l/ja/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (JA).
packages/twenty-docs/l/ko/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (KO).
packages/twenty-docs/l/pt/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (PT).
packages/twenty-docs/l/ro/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (RO).
packages/twenty-docs/l/ru/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (RU).
packages/twenty-docs/l/tr/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (TR).
packages/twenty-docs/l/zh/developers/self-host/capabilities/troubleshooting.mdx Same troubleshooting cleanup (ZH).
nx.json Removes deprecated env-var from storybook build command.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 69 to 71
Run only the services you need, instead of `npx nx start`. Ad esempio, se lavori sul server, esegui solo `npx nx worker twenty-server`

**If it does not work:**
Copy link

Copilot AI Mar 5, 2026

Choose a reason for hiding this comment

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

This Italian localized troubleshooting page still contains English sentences/headers (e.g., “Run only the services you need” / “If it does not work”). Since this section is user-facing documentation, it should be fully translated to Italian (or replaced with the localized equivalent) for consistency with the rest of the file.

Copilot uses AI. Check for mistakes.
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.

3 participants