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

Switch typescript skeleton to zodern:types and test that it works #12510

Merged
merged 1 commit into from
Feb 10, 2023

Conversation

ebroder
Copy link
Contributor

@ebroder ebroder commented Feb 10, 2023

As type definitions are moved to be shipped directly with the core Meteor packages, the @types/meteor NPM package is trending towards deprecation, so we should steer people to use the preferred way of pulling in type definitions.

Additionally, add a test to make sure we're not steering them too far astray.

As type definitions are moved to be shipped directly with the core
Meteor packages, the @types/meteor NPM package is trending towards
deprecation, so we should steer people to use the preferred way of
pulling in type definitions.

Additionally, add a test to make sure we're not steering them too far
astray.
Copy link
Contributor

@Grubba27 Grubba27 left a comment

Choose a reason for hiding this comment

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

LGTM

@Grubba27 Grubba27 merged commit d659f63 into meteor:release-2.11 Feb 10, 2023
ebroder added a commit to ebroder/meteor-types that referenced this pull request Feb 11, 2023
Since we're already reaching into the Meteor ProjectContext to get the
package catalog, we can also grab the root that Meteor is using as its
package store while we're in the area.

This should fix using this package with a Meteor checkout, instead of a
released version of Meteor, as when running from a checkout, Meteor
creates a `.meteor` directory in the source tree, rather than using the
`.meteor` directory in `$HOME` or `$LOCALAPPDATA`.

This should additionally fix the integration test added in
meteor/meteor#12510.
ebroder added a commit to ebroder/meteor-types that referenced this pull request Feb 13, 2023
When running with a Meteor checkout, instead of a released version of
Meteor, Meteor creates a `.meteor` directory in its own source tree,
rather than using the `.meteor` directory in `$HOME` or `$LOCALDATA`.
This means that when we use `zodern:types` in (e.g.) a self-test, such
as the one added in meteor/meteor#12510, packages would not end up where
we expected them.

Unfortunately, when the package is published, it gets loaded after
Meteor has already parsed the project context.

So instead of reaching into Meteor's ProjectContext to get the package
catalog, we instead create our own temporary context, following the
example of what Meteor does for `meteor show`. Once we've done that, we
can grab both the package catalog and the root of the package store.
ebroder added a commit to ebroder/meteor-types that referenced this pull request Feb 23, 2023
Since we're already reaching into the Meteor ProjectContext to get the
package catalog, we can also grab the root that Meteor is using as its
package store while we're in the area.

This should fix using this package with a Meteor checkout, instead of a
released version of Meteor, as when running from a checkout, Meteor
creates a `.meteor` directory in the source tree, rather than using the
`.meteor` directory in `$HOME` or `$LOCALAPPDATA`.

This should additionally fix the integration test added in
meteor/meteor#12510.
ebroder added a commit to ebroder/meteor-types that referenced this pull request Feb 23, 2023
Since we're already reaching into the Meteor ProjectContext to get the
package catalog, we can also grab the root that Meteor is using as its
package store while we're in the area.

This should fix using this package with a Meteor checkout, instead of a
released version of Meteor, as when running from a checkout, Meteor
creates a `.meteor` directory in the source tree, rather than using the
`.meteor` directory in `$HOME` or `$LOCALAPPDATA`.

This should additionally fix the integration test added in
meteor/meteor#12510.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants