cli icon indicating copy to clipboard operation
cli copied to clipboard

Weird behaviour of `nuxt typecheck` and '@nuxt/kit' in tsconfig.json compilerOptions.paths '#build/*' alias

Open simkuns opened this issue 1 year ago • 0 comments

When running nuxt typecheck in a project without .nuxt directory @nuxt/kit creates an alias for #build, but does not create an alias for #build/* in tsConfig.compilerOptions.paths which causes typecheck to fail.

Creating empty .nuxt directory or swapping lines https://github.com/nuxt/cli/blob/34e622450650ab59b0c85aaba71894c8e2bb18f8/src/commands/typecheck.ts#L42 and https://github.com/nuxt/cli/blob/34e622450650ab59b0c85aaba71894c8e2bb18f8/src/commands/typecheck.ts#L43 similarly to nuxt prepare command allows @nuxt/kit to add #build/* alias in tsconfig.json which causes typecheck to succeed.

simkuns avatar May 17 '24 15:05 simkuns