From 48bd0e5503360057327aa03fb76436b278f055a5 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 27 Apr 2026 00:42:37 +0000 Subject: [PATCH 1/3] docs: align `_tools/pkgs/dep-list` with namespace JSDoc convention Added `@example` blocks to the public `depList` function's JSDoc (present in 92% of `_tools/pkgs` siblings, 23/25). Examples are lifted from the package README's existing usage snippets; no behavioral or signature changes. https://claude.ai/code/session_018TZhAvyL3P8FYzhGm4G1LH --- .../@stdlib/_tools/pkgs/dep-list/lib/main.js | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/lib/node_modules/@stdlib/_tools/pkgs/dep-list/lib/main.js b/lib/node_modules/@stdlib/_tools/pkgs/dep-list/lib/main.js index b13cf63a3620..4663bd363746 100644 --- a/lib/node_modules/@stdlib/_tools/pkgs/dep-list/lib/main.js +++ b/lib/node_modules/@stdlib/_tools/pkgs/dep-list/lib/main.js @@ -60,6 +60,18 @@ function ascending( a, b ) { * @param {boolean} [options.manifest=true] - boolean indicating whether to return dependencies from `manifest.json` files * @throws {TypeError} first argument must be a string * @returns {(StringArray|EmptyArray)} dependencies +* +* @example +* var deps = depList( '@stdlib/assert/is-number-array' ); +* // returns [...] +* +* @example +* var opts = { +* 'dev': true +* }; +* +* var devDeps = depList( '@stdlib/utils/keys', opts ); +* // returns [...] */ function depList( pkg, options ) { var opts; From 84ef20be883b0c9cc2babb181c7827b3bb59ec87 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 27 Apr 2026 00:42:42 +0000 Subject: [PATCH 2/3] docs: align `_tools/pkgs/namespace-deps` with namespace JSDoc convention Added `@example` blocks to the public `namespaceDeps` function's JSDoc (present in 92% of `_tools/pkgs` siblings, 23/25). Examples are lifted from the package README's existing usage snippets; no behavioral or signature changes. https://claude.ai/code/session_018TZhAvyL3P8FYzhGm4G1LH --- .../@stdlib/_tools/pkgs/namespace-deps/lib/main.js | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/lib/node_modules/@stdlib/_tools/pkgs/namespace-deps/lib/main.js b/lib/node_modules/@stdlib/_tools/pkgs/namespace-deps/lib/main.js index a8e2261e82aa..2f818b0e66d2 100644 --- a/lib/node_modules/@stdlib/_tools/pkgs/namespace-deps/lib/main.js +++ b/lib/node_modules/@stdlib/_tools/pkgs/namespace-deps/lib/main.js @@ -60,6 +60,18 @@ function ascending( a, b ) { * @param {number} [options.level=1] - dependency level * @throws {TypeError} first argument must be a string * @returns {(StringArray|EmptyArray)} dependencies +* +* @example +* var deps = namespaceDeps( '@stdlib/assert' ); +* // returns [...] +* +* @example +* var opts = { +* 'dev': true +* }; +* +* var devDeps = namespaceDeps( '@stdlib/assert', opts ); +* // returns [...] */ function namespaceDeps( pkg, options ) { var opts; From 4bfc4992c7e448307cd4e8c5d28000e93090515a Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 27 Apr 2026 00:47:12 +0000 Subject: [PATCH 3/3] docs: avoid module-scope name collision in `_tools/pkgs/{dep-list,namespace-deps}` examples Renamed the JSDoc `@example` result variable from `deps`/`devDeps` to `out` so the example does not shadow the module-scope `var deps = require( './deps.js' );` import. Without this rename, the example-runner shadowed the internal `deps` function and threw `deps is not a function` when invoking the public function. https://claude.ai/code/session_018TZhAvyL3P8FYzhGm4G1LH --- lib/node_modules/@stdlib/_tools/pkgs/dep-list/lib/main.js | 4 ++-- .../@stdlib/_tools/pkgs/namespace-deps/lib/main.js | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/node_modules/@stdlib/_tools/pkgs/dep-list/lib/main.js b/lib/node_modules/@stdlib/_tools/pkgs/dep-list/lib/main.js index 4663bd363746..0a9b74289f30 100644 --- a/lib/node_modules/@stdlib/_tools/pkgs/dep-list/lib/main.js +++ b/lib/node_modules/@stdlib/_tools/pkgs/dep-list/lib/main.js @@ -62,7 +62,7 @@ function ascending( a, b ) { * @returns {(StringArray|EmptyArray)} dependencies * * @example -* var deps = depList( '@stdlib/assert/is-number-array' ); +* var out = depList( '@stdlib/assert/is-number-array' ); * // returns [...] * * @example @@ -70,7 +70,7 @@ function ascending( a, b ) { * 'dev': true * }; * -* var devDeps = depList( '@stdlib/utils/keys', opts ); +* var out = depList( '@stdlib/utils/keys', opts ); * // returns [...] */ function depList( pkg, options ) { diff --git a/lib/node_modules/@stdlib/_tools/pkgs/namespace-deps/lib/main.js b/lib/node_modules/@stdlib/_tools/pkgs/namespace-deps/lib/main.js index 2f818b0e66d2..dae022d0730d 100644 --- a/lib/node_modules/@stdlib/_tools/pkgs/namespace-deps/lib/main.js +++ b/lib/node_modules/@stdlib/_tools/pkgs/namespace-deps/lib/main.js @@ -62,7 +62,7 @@ function ascending( a, b ) { * @returns {(StringArray|EmptyArray)} dependencies * * @example -* var deps = namespaceDeps( '@stdlib/assert' ); +* var out = namespaceDeps( '@stdlib/assert' ); * // returns [...] * * @example @@ -70,7 +70,7 @@ function ascending( a, b ) { * 'dev': true * }; * -* var devDeps = namespaceDeps( '@stdlib/assert', opts ); +* var out = namespaceDeps( '@stdlib/assert', opts ); * // returns [...] */ function namespaceDeps( pkg, options ) {