Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

fix(nuxi): build all types on typecheck command #5437

Merged
merged 4 commits into from
Aug 23, 2022
Merged

fix(nuxi): build all types on typecheck command #5437

merged 4 commits into from
Aug 23, 2022

Conversation

cawa-93
Copy link
Contributor

@cawa-93 cawa-93 commented Jun 13, 2022

πŸ”— Linked issue

fix: nuxt/nuxt#12845

❓ Type of change

  • πŸ“– Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

The writeTypes method only creates nuxt.d.ts and types/nitro.d.ts, ignoring plugins types, components, autoimport, composables and so on. As a result, type checking fails with false positives errors.

The easiest way to generate all types is to call the buildNuxt method with the _prepare: true option for better performance

πŸ“ Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@netlify
Copy link

netlify bot commented Jun 13, 2022

βœ… Deploy Preview for nuxt3-docs canceled.

Name Link
πŸ”¨ Latest commit a222ee0
πŸ” Latest deploy log https://app.netlify.com/sites/nuxt3-docs/deploys/63053d5a8fcf2400085362c5

@cawa-93 cawa-93 marked this pull request as draft June 13, 2022 09:41
@cawa-93 cawa-93 marked this pull request as ready for review June 13, 2022 09:44
@cawa-93 cawa-93 changed the title fix: build all types on typecheck command fix(nuxi): build all types on typecheck command Jun 13, 2022
@ady642
Copy link

ady642 commented Aug 9, 2022

I think we can merge this PR

@pi0 pi0 requested a review from danielroe August 23, 2022 20:54
Copy link
Member

@pi0 pi0 left a comment

Choose a reason for hiding this comment

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

Thanks <3 LGTM waiting for @danielroe to double check.

Copy link
Member

@danielroe danielroe left a comment

Choose a reason for hiding this comment

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

looks good to me

@pi0 pi0 merged commit 422d5c4 into nuxt:main Aug 23, 2022
@cawa-93 cawa-93 deleted the patch-2 branch August 23, 2022 21:05
@pi0 pi0 mentioned this pull request Aug 26, 2022
@danielroe danielroe added the 3.x label Jan 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

nuxi typecheck shortcut
4 participants