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

feat(unstable): add @ts-types and clean up @deno-types #444

Conversation

lucacasonato
Copy link
Member

@lucacasonato lucacasonato commented Apr 16, 2024

This allows a @ts-types pragma to be used
instead of the @deno-types pragma. The
@ts-types pragma does not allow unquoted
specifiers.

This also removes the leadingComment field in
the DependencyDescriptor struct in favor of a
typesSpecifier field. This requires bumping the
ModuleInfo version to 2.

Copy link
Member

@dsherret dsherret left a comment

Choose a reason for hiding this comment

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

If we do make this breaking change, then we should add a test for how Deno now handles the old moduleGraph1 and then put this new data in moduleGraph2

@lucacasonato lucacasonato force-pushed the clean_up_deno_types_in_dependency_descriptor branch 2 times, most recently from 7c20979 to 0b31790 Compare April 19, 2024 10:06
@lucacasonato lucacasonato changed the title chore: clean up @deno-types handling in DependencyDescriptor feat: add @ts-types and clean up @deno-types Apr 19, 2024
src/packages.rs Outdated Show resolved Hide resolved
@dsherret dsherret changed the title feat: add @ts-types and clean up @deno-types feat(unstable): add @ts-types and clean up @deno-types Apr 24, 2024
Copy link
Member

@dsherret dsherret left a comment

Choose a reason for hiding this comment

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

LGTM!

src/graph.rs Outdated Show resolved Hide resolved
This allows a `@ts-types` pragma to be used
instead of the `@deno-types` pragma. The
`@ts-types` pragma does not allow unquoted
specifiers.

This also removes the `leadingComment` field in
the `DependencyDescriptor` struct in favor of a
`typesSpecifier` field. This requires bumping the
`ModuleInfo` version to 2.
@lucacasonato lucacasonato force-pushed the clean_up_deno_types_in_dependency_descriptor branch from 0b31790 to 8aed3b2 Compare April 24, 2024 18:47
@dsherret dsherret merged commit 570b480 into denoland:main Apr 24, 2024
4 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