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

Improve tsconfig.json #18

Merged
merged 1 commit into from
Oct 24, 2024
Merged

Improve tsconfig.json #18

merged 1 commit into from
Oct 24, 2024

Conversation

harmony7
Copy link
Member

This PR enhances the project's TypeScript settings:

  • Uses moduleResolution: bundler to enable conditional imports and exports
    This is described in this article and works better for our use case because it enables:
    • Named imports and named exports
    • Custom conditions (see below)
  • Add "fastly" custom condition to match js-compute-runtime
    • js-compute-runtime adds this condition in its "bundle" step so it makes sense to allow TypeScript to resolve these as well.
  • Remove skipLibCheck as that is no longer needed
    • This was only needed when Fastly Compute's types file conflicted with Node.js in the past.

* Use moduleResolution: bundler to enable conditional imports and exports
* Add "fastly" custom condition to match js-compute-runtime
* Remove skipLibCheck as that is no longer needed
@harmony7 harmony7 merged commit 6a02ce9 into main Oct 24, 2024
3 of 5 checks passed
@harmony7 harmony7 deleted the kats/tsconfig branch October 24, 2024 17:55
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