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

Keep @types/node types at v8. #2344

Merged
merged 1 commit into from
Feb 20, 2019
Merged

Keep @types/node types at v8. #2344

merged 1 commit into from
Feb 20, 2019

Conversation

abernix
Copy link
Member

@abernix abernix commented Feb 20, 2019

While there are newer types available for newer Node.js APIs, the 8.x range still gets most of the important updates via back-ports on the DefinitelyTyped repository. I believe it'll be safer to limit the types to the version which we intend on developing for most directly, which is Node.js 8. Node.js 10 has newer APIs but until we can drop Node.js 8 support (which is not at all anytime soon), we should try to stick to the 8.x API types.

We will drop Node.js 6 support in the next major version of Apollo Server since it will end its "Long-Term Support" coverage in April 2019.

Hopefully this will auto-close #2302. 😉

While there are newer types available for newer Node.js APIs, the `8.x` range still gets most of the important updates.  I believe it'll be safer to limit the types to the version which we intend on developing for most directly, which is Node.js 8.  Node.js 10 has newer APIs but until we can drop Node.js 8 support (which is not at all anytime soon), we should try to stick to the `8.x` API types.
@abernix abernix merged commit 236285d into master Feb 20, 2019
@abernix abernix deleted the abernix/types-node-v8-only branch February 20, 2019 13:02
abernix added a commit that referenced this pull request Feb 20, 2019
Follows-up on #2344 with the appropriate changes to the `package.json` as
well.
@abernix
Copy link
Member Author

abernix commented Feb 20, 2019

Also, see 0f75909.

abernix added a commit that referenced this pull request Feb 20, 2019
…rred.

This is necessary after the changes in 0f75909
and #2344, as the
`AddressInfo` type didn't become available until a future version of
`@types/node`.

Regardless, it seems to me that this should be inferred without any problem
and we don't actually rely on the `AddressInfo` type, and instead are only
looking for an interface which has `port`, `address` and `family`, as the
inferred return value from `http.Server.prototype.address()` does.
abernix added a commit to apollographql/apollo-tooling that referenced this pull request Mar 12, 2019
In the same spirit as apollographql/apollo-server#2344,
this should hopefully _gently_ help us not use types which aren't available
in all of the versions of Node.js which we currently target.
trevor-scheer pushed a commit that referenced this pull request May 6, 2020
In the same spirit as #2344,
this should hopefully _gently_ help us not use types which aren't available
in all of the versions of Node.js which we currently target.
trevor-scheer pushed a commit that referenced this pull request May 14, 2020
In the same spirit as #2344,
this should hopefully _gently_ help us not use types which aren't available
in all of the versions of Node.js which we currently target.
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 22, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant