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

Typecheck issues with @remix-run/dev #9028

Closed
JoblersTune opened this issue Mar 11, 2024 · 1 comment
Closed

Typecheck issues with @remix-run/dev #9028

JoblersTune opened this issue Mar 11, 2024 · 1 comment

Comments

@JoblersTune
Copy link

JoblersTune commented Mar 11, 2024

Reproduction

Running a typecheck with Typescript tsc I get errors in the node_modules folder with the two latest releases, 2.7 and 2.8.
I saw the issue with a PR on the Rafiki repository where we're trying to upgrade our dependencies. You can check it out here:
interledger/rafiki#2439
The failing test output is here:
https://github.com/interledger/rafiki/actions/runs/8203165752/job/22435478039?pr=2439

System Info

System:
    OS: Linux 6.1 Ubuntu 22.04.3 LTS 22.04.3 LTS (Jammy Jellyfish)
    CPU: (16) x64 13th Gen Intel(R) Core(TM) i7-1360P
    Memory: 7.63 GB / 15.23 GB
    Container: Yes
    Shell: 5.1.16 - /bin/bash
  Binaries:
    Node: 18.19.1 - ~/.nvm/versions/node/v18.19.1/bin/node
    npm: 10.2.4 - ~/.nvm/versions/node/v18.19.1/bin/npm
    pnpm: 8.15.4 - ~/.nvm/versions/node/v18.19.1/bin/pnpm
  Browsers:
    Chrome: 122.0.6261.57

Used Package Manager

npm

Expected Behavior

I expect no type errors. To achieve this I have to downgrade to version 2.6

Actual Behavior

> tsc

../../node_modules/.pnpm/@[email protected]_@[email protected][email protected]/node_modules/@remix-run/dev/dist/vite/cloudflare-proxy-plugin.d.ts:3:66 - error TS2307: Cannot find module 'wrangler' or its corresponding type declarations.

3 import { type GetPlatformProxyOptions, type PlatformProxy } from "wrangler";
                                                                   ~~~~~~~~~~

../../node_modules/.pnpm/@[email protected]_@[email protected][email protected]/node_modules/@remix-run/dev/dist/vite/plugin.d.ts:26:23 - error TS2315: Type 'Plugin_2' is not generic.

26     plugins: readonly Vite.Plugin<any>[];
                         ~~~~~~~~~~~~~~~~

../../node_modules/.pnpm/@[email protected]_@[email protected][email protected]/node_modules/@remix-run/dev/dist/vite/plugin.d.ts:37:18 - error TS2724: '/node_modules/.pnpm/[email protected]_@[email protected]/node_modules/vite/dist/node/index"' has no exported member named 'ResolvedWorkerOptions'. Did you mean 'ResolveWorkerOptions'?

37     worker: Vite.ResolvedWorkerOptions;
                    ~~~~~~~~~~~~~~~~~~~~~


Found 3 errors in 2 files.

Errors  Files
     1  ../../node_modules/.pnpm/@[email protected]_@[email protected][email protected]/node_modules/@remix-run/dev/dist/vite/cloudflare-proxy-plugin.d.ts:3
     2  ../../node_modules/.pnpm/@[email protected]_@[email protected][email protected]/node_modules/@remix-run/dev/dist/vite/plugin.d.ts:26
@pcattori
Copy link
Contributor

You should enable skipLibCheck in your tsconfig.json so that type errors originating from dependencies doesn't cause typechecking to fail. See #8594 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants