Skip to content

Conversation

@daniluk4000
Copy link
Contributor

Resolves #4470.

image

When debugging I found that our first file is our internal node modules component.

But since canonicalRootFileNamesVersion was set, and this file wasn't root, globalTypesHolder was never set.

@daniluk4000
Copy link
Contributor Author

#4452 could potentially break something else tho, but this fixes this problem for our case.

@daniluk4000 daniluk4000 changed the title fix(#4470): Resolve potential any in templates if first checked file was not root fix(#4470): any in templates if first checked file was not root Jul 3, 2024
@daniluk4000 daniluk4000 changed the title fix(#4470): any in templates if first checked file was not root fix: any in templates if first checked file was not root Jul 3, 2024
@johnsoncodehk
Copy link
Member

The current test infrastructure makes it difficult to add test cases for this bug, but the change looks good to me, thanks for looking into it!

@johnsoncodehk johnsoncodehk changed the title fix: any in templates if first checked file was not root fix(language-core): any in templates if first checked file was not root Jul 4, 2024
@johnsoncodehk johnsoncodehk merged commit 2eebf34 into vuejs:master Jul 4, 2024
@daniluk4000 daniluk4000 deleted the fix/4470 branch July 4, 2024 07:39
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.

infer type in template unexpectedly after v2.0.19

2 participants