[webpack-env] make __WebpackModuleApi.Module compatible with NodeJS.Module - #47516
Conversation
|
@jamescdavis Thank you for submitting this PR! This is a live comment which I will keep updated. 1 package in this PRCode ReviewsBecause you edited one package and updated the tests (👏), I can help you merge this PR once someone else signs off on it. Status
Once every item on this list is checked, I'll ask you for permission to merge and publish the changes. Diagnostic Information: What the bot saw about this PR{
"type": "info",
"now": "-",
"pr_number": 47516,
"author": "jamescdavis",
"owners": [
"use-strict",
"rhonsby"
],
"dangerLevel": "ScopedAndTested",
"headCommitAbbrOid": "31ed0f6",
"headCommitOid": "31ed0f66bdb26883f319f61ab65f16b5db948acf",
"mergeIsRequested": false,
"stalenessInDays": 0,
"lastPushDate": "2020-09-12T16:40:37.000Z",
"lastCommentDate": "2020-09-17T14:50:24.000Z",
"maintainerBlessed": true,
"reviewLink": "https://github.com/DefinitelyTyped/DefinitelyTyped/pull/47516/files",
"hasMergeConflict": false,
"authorIsOwner": false,
"isFirstContribution": false,
"popularityLevel": "Critical",
"newPackages": [],
"packages": [
"webpack-env"
],
"files": [
{
"path": "types/webpack-env/index.d.ts",
"kind": "definition",
"package": "webpack-env"
},
{
"path": "types/webpack-env/webpack-env-tests.ts",
"kind": "test",
"package": "webpack-env"
}
],
"hasDismissedReview": false,
"ciResult": "pass",
"lastReviewDate": "2020-09-12T17:04:49.000Z",
"reviewersWithStaleReviews": [],
"approvalFlags": 1,
"isChangesRequested": false
} |
|
🔔 @use-strict @rhonsby — please review this PR in the next few days. Be sure to explicitly select |
|
👋 Hi there! I’ve run some quick measurements against master and your PR. These metrics should help the humans reviewing this PR gauge whether it might negatively affect compile times or editor responsiveness for users who install these typings. Let’s review the numbers, shall we? Comparison details 📊
It looks like nothing changed too much. I won’t post performance data again unless it gets worse. |
|
Updated numbers for you here from b0875df. Comparison details 📊
It looks like there are several metrics that changed quite a bit. You might want to take a look and make sure your changes won’t cause slow-downs for users consuming these types. |
| filename: string; | ||
| loaded: boolean; | ||
| parent: NodeModule | null; | ||
| parent: NodeModule | null | undefined; |
There was a problem hiding this comment.
I could have used
| parent: NodeModule | null | undefined; | |
| parent?: NodeModule | null; |
of course, but I was going for exact parity with the node types:
DefinitelyTyped/types/node/ts3.1/globals.d.ts
Line 580 in 1c2240f
|
I'm assuming the perf change is only due to the import of the node types in the test. |
Co-authored-by: ExE Boss <3889017+ExE-Boss@users.noreply.github.com>
|
@ExE-Boss Thank you for reviewing this PR! The author has pushed new commits since your last review. Could you take another look and submit a fresh review? |
|
Updated numbers for you here from dbb655b. Comparison details 📊
It looks like there are several metrics that changed quite a bit. You might want to take a look and make sure your changes won’t cause slow-downs for users consuming these types. |
Remove once DefinitelyTyped/DefinitelyTyped#47516 is merged
|
How can I get these |
|
@dep-dt Ask in https://github.com/DefinitelyTyped/dt-mergebot |
|
@use-strict @rhonsby looks like DT maintainers would like you to review. 🙏 |
|
This fixes issue #47602 and closes PR #47607, so this should be placed in the PR description: |
|
Is it possible to use this without a release to npm? |
Since its just a typescript issue, you can manually edit file and add the |
|
@olyop Not really feasible in CI 😂 hopefully this lands soon, or is there some workaround I can do with a flag in tsconfig.json? |
|
@ulrikstrid pin |
|
Will this still get merged in case a maintainer review never happens? |
|
|
❤️ @sandersn |
|
This was released as @types/webpack-env@1.15.3. |
…odule (DefinitelyTyped#47516) * fix: make __WebpackModuleApi.Module compatible with NodeJS.Module * test: import node types in test * test: use reference instead of import Co-authored-by: ExE Boss <3889017+ExE-Boss@users.noreply.github.com> Co-authored-by: ExE Boss <3889017+ExE-Boss@users.noreply.github.com>
A recent update to
nodetypes made__WebpackModuleApi.Moduleincompatible withNodeJS.Module. Importing the node types in the test reveals this issue and ensures compatibility.Please fill in this template.
npm test.)npm run lint package-name(ortscif notslint.jsonis present).If changing an existing definition:
tslint.jsoncontaining{ "extends": "dtslint/dt.json" }. If for reason the any rule need to be disabled, disable it for that line using// tslint:disable-next-line [ruleName]and not for whole package so that the need for disabling can be reviewed.