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

fix tsconfig module #7

Merged
merged 3 commits into from
Mar 24, 2024
Merged

fix tsconfig module #7

merged 3 commits into from
Mar 24, 2024

Conversation

guoyunhe
Copy link
Contributor

@guoyunhe guoyunhe commented Mar 24, 2024

πŸ”— Linked issue

❓ Type of change

  • 🐞 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

After running the upgrade-kit, project failed to start and TypeScript complain of type not found for '@adonisjs/core/http'. The reason is that old tsconfig.json still has:

{
  "compilerOptions": {
    "module": "commonjs",
    "moduleResolution": "node",
  }
}

To make it work, these options should be deleted so that the options from extending package take effects.

πŸ“ Checklist

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

@Julien-R44
Copy link
Member

in this patch we are extending the tsconfig :

tsConfig.extends = '@adonisjs/tsconfig/tsconfig.app.json' 

moduleResolution and module are specified in that file

@guoyunhe
Copy link
Contributor Author

@Julien-R44 then you should delete those keys from migrating project's tsconfig.json, otherwise the extending won't work.

@Julien-R44
Copy link
Member

Cool thanks!

@Julien-R44 Julien-R44 merged commit 365116f into adonisjs:main Mar 24, 2024
2 of 6 checks passed
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.

2 participants