Conversation
targos
commented
Sep 26, 2021
| getUptime(): number; | ||
| getTotalMem(): number; | ||
| getFreeMem(): number; | ||
| getCPUs(): Array<string | number>; |
There was a problem hiding this comment.
| getCPUs(): Array<string | number>; | |
| getCPUs(): (string | number)[]; |
for consistency with other dts
There was a problem hiding this comment.
I have a preference to use type[] for simple types and Array<types> for more complex ones
typings/internalBinding/os.d.ts
Outdated
| getTotalMem(): number; | ||
| getFreeMem(): number; | ||
| getCPUs(): Array<string | number>; | ||
| getInterfaceAddresses(ctx: object): Array<string | number | boolean> | undefined; |
There was a problem hiding this comment.
| getInterfaceAddresses(ctx: object): Array<string | number | boolean> | undefined; | |
| getInterfaceAddresses(ctx: object): (string | number | boolean)[] | undefined; |
Commit Queue failed- Loading data for nodejs/node/pull/40222 ✔ Done loading data for nodejs/node/pull/40222 ----------------------------------- PR info ------------------------------------ Title typings: improve typings (#40222) Author Michaël Zasso (@targos) Branch targos:typings -> nodejs:master Labels author ready, typings Commits 5 - typings: fix declaration of primordials - typings: define types for timers binding - typings: add missing types to options and util bindings - typings: define types for os binding - fixup! typings: define types for os binding Committers 1 - Michaël Zasso PR-URL: https://github.com/nodejs/node/pull/40222 Fixes: https://github.com/https://github.com/nodejs/node/issues/40144 Reviewed-By: Tobias Nießen Reviewed-By: Evan Lucas Reviewed-By: Zijian Liu Reviewed-By: James M Snell Reviewed-By: Michael Dawson ------------------------------ Generated metadata ------------------------------ PR-URL: https://github.com/nodejs/node/pull/40222 Fixes: https://github.com/https://github.com/nodejs/node/issues/40144 Reviewed-By: Tobias Nießen Reviewed-By: Evan Lucas Reviewed-By: Zijian Liu Reviewed-By: James M Snell Reviewed-By: Michael Dawson -------------------------------------------------------------------------------- ℹ This PR was created on Sun, 26 Sep 2021 14:36:03 GMT ✔ Approvals: 5 ✔ - Tobias Nießen (@tniessen) (TSC): https://github.com/nodejs/node/pull/40222#pullrequestreview-763706951 ✔ - Evan Lucas (@evanlucas): https://github.com/nodejs/node/pull/40222#pullrequestreview-764570178 ✔ - Zijian Liu (@Lxxyx): https://github.com/nodejs/node/pull/40222#pullrequestreview-766148910 ✔ - James M Snell (@jasnell) (TSC): https://github.com/nodejs/node/pull/40222#pullrequestreview-767943198 ✔ - Michael Dawson (@mhdawson) (TSC): https://github.com/nodejs/node/pull/40222#pullrequestreview-769403509 ✔ Last GitHub Actions successful ℹ Green GitHub Actions CI is sufficient -------------------------------------------------------------------------------- ✔ No git cherry-pick in progress ✔ No git am in progress ✔ No git rebase in progress -------------------------------------------------------------------------------- - Bringing origin/master up to date... From https://github.com/nodejs/node * branch master -> FETCH_HEAD ✔ origin/master is now up-to-date - Downloading patch for 40222 From https://github.com/nodejs/node * branch refs/pull/40222/merge -> FETCH_HEAD ✔ Fetched commits as eaa59571e0fd..795db39025ef -------------------------------------------------------------------------------- [master 0b4ed8fe7f] typings: fix declaration of primordials Author: Michaël Zasso Date: Sun Sep 26 12:22:11 2021 +0200 1 file changed, 5 insertions(+), 1 deletion(-) [master c5028c4cfb] typings: define types for timers binding Author: Michaël Zasso Date: Sun Sep 26 15:47:14 2021 +0200 2 files changed, 9 insertions(+) create mode 100644 typings/internalBinding/timers.d.ts [master 7b025d4363] typings: add missing types to options and util bindings Author: Michaël Zasso Date: Sun Sep 26 16:07:13 2021 +0200 2 files changed, 2 insertions(+) [master 03be0fbe11] typings: define types for os binding Author: Michaël Zasso Date: Sun Sep 26 16:28:40 2021 +0200 2 files changed, 22 insertions(+) create mode 100644 typings/internalBinding/os.d.ts [master 88e9b9da17] fixup! typings: define types for os binding Author: Michaël Zasso Date: Mon Sep 27 16:50:49 2021 +0200 1 file changed, 7 insertions(+), 7 deletions(-) ✔ Patches applied There are 5 commits in the PR. Attempting autorebase. Rebasing (2/9)https://github.com/nodejs/node/actions/runs/1323958359 |
|
Landed in 8068f40...9467cba |
PR-URL: #40222 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Zijian Liu <lxxyxzj@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
PR-URL: #40222 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Zijian Liu <lxxyxzj@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
PR-URL: #40222 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Zijian Liu <lxxyxzj@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
PR-URL: #40222 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Zijian Liu <lxxyxzj@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
PR-URL: #40222 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Zijian Liu <lxxyxzj@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
PR-URL: #40222 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Zijian Liu <lxxyxzj@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com>