Skip to content

Commit adc0378

Browse files
stdlib-botkgryte
andauthored
docs: update namespace TypeScript declarations
PR-URL: stdlib-js#993 Co-authored-by: Athan Reines <kgryte@gmail.com> Reviewed-by: Athan Reines <kgryte@gmail.com>
1 parent 8acd137 commit adc0378

8 files changed

Lines changed: 716 additions & 13 deletions

File tree

etc/npm/deps.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
acorn@"^8.1.0" acorn-loose@"^8.0.2" acorn-walk@"^8.0.2" d3-format@"^1.0.0" d3-scale@"^1.0.0" d3-shape@"^1.0.0" d3-time-format@"^2.0.0" debug@"^2.6.9" glob@"^7.0.5" minimist@"^1.2.0" readable-stream@"^2.1.4" resolve@"^1.1.7" vdom-to-html@"^2.3.0" virtual-dom@"^2.1.1" 0x@"^4.10.2" @commitlint/cli@"^17.4.4" @commitlint/cz-commitlint@"^17.4.4" @kaciras/deasync@"^1.0.1" @types/node@"^13.9.0" ajv@"^5.2.2" browser-pack-flat@"^3.0.0" browserify@"^17.0.0" bundle-collapser@"^1.3.0" c8@"^7.12.0" chai@"^3.5.0" cheerio@"^1.0.0-rc.12" commitizen@"^4.3.0" common-shakeify@"^0.6.0" conventional-changelog-conventionalcommits@"^5.0.0" doctrine@"^3.0.0" dtslint@"^3.3.0" envify@"^4.0.0" eslint@"^8.0.1" eslint-plugin-node@"^11.1.0" factor-bundle@"^2.5.0" gh-pages@"git+https://github.com/Planeshifter/gh-pages.git#main" inquirer@"^8.0.0" jsdoc@"^3.4.0" lunr@"^2.3.9" mathjax-node@"^2.0.1" mathjax-node-sre@"^3.0.0" mkdirp@"^0.5.1" mustache@"^4.0.0" parse-link-header@"^1.0.1" plato@"^1.5.0" process@"^0.11.10" proxyquire@"^2.0.0" proxyquire-universal@"^2.0.0" proxyquireify@"^3.1.1" read-installed@"^4.0.3" rehype@"^9.0.0" rehype-highlight@"^3.0.0" remark@"^11.0.1" remark-cli@"^7.0.0" remark-frontmatter@"^1.2.0" remark-html@"^10.0.0" remark-lint@"^6.0.0" remark-lint-blockquote-indentation@"^1.0.0" remark-lint-checkbox-character-style@"^1.0.0" remark-lint-checkbox-content-indent@"^1.0.0" remark-lint-code-block-style@"^1.0.0" remark-lint-definition-case@"^1.0.0" remark-lint-definition-spacing@"^1.0.0" remark-lint-emphasis-marker@"^1.0.0" remark-lint-fenced-code-flag@"^1.0.0" remark-lint-fenced-code-marker@"^1.0.0" remark-lint-file-extension@"^1.0.0" remark-lint-final-definition@"^1.0.0" remark-lint-final-newline@"^1.0.0" remark-lint-first-heading-level@"^1.1.0" remark-lint-hard-break-spaces@"^1.0.1" remark-lint-heading-increment@"^1.0.0" remark-lint-heading-style@"^1.0.0" remark-lint-linebreak-style@"^1.0.0" remark-lint-link-title-style@"^1.0.0" remark-lint-list-item-bullet-indent@"^1.0.0" remark-lint-list-item-content-indent@"^1.0.0" remark-lint-list-item-indent@"^1.0.0" remark-lint-list-item-spacing@"^1.1.0" remark-lint-maximum-heading-length@"^1.0.0" remark-lint-maximum-line-length@"^1.0.0" remark-lint-no-auto-link-without-protocol@"^1.0.0" remark-lint-no-blockquote-without-marker@"^2.0.0" remark-lint-no-consecutive-blank-lines@"^1.0.0" remark-lint-no-duplicate-definitions@"^1.0.0" remark-lint-no-duplicate-headings@"^1.0.0" remark-lint-no-duplicate-headings-in-section@"^1.0.0" remark-lint-no-emphasis-as-heading@"^1.0.0" remark-lint-no-empty-url@"^1.0.1" remark-lint-no-file-name-articles@"^1.0.0" remark-lint-no-file-name-consecutive-dashes@"^1.0.0" remark-lint-no-file-name-irregular-characters@"^1.0.0" remark-lint-no-file-name-mixed-case@"^1.0.0" remark-lint-no-file-name-outer-dashes@"^1.0.1" remark-lint-no-heading-content-indent@"^1.0.0" remark-lint-no-heading-indent@"^1.0.0" remark-lint-no-heading-like-paragraph@"^1.0.0" remark-lint-no-heading-punctuation@"^1.0.0" remark-lint-no-html@"^1.0.0" remark-lint-no-inline-padding@"^1.0.0" remark-lint-no-literal-urls@"^1.0.0" remark-lint-no-missing-blank-lines@"^1.0.0" remark-lint-no-multiple-toplevel-headings@"^1.0.0" remark-lint-no-paragraph-content-indent@"^1.0.1" remark-lint-no-reference-like-url@"^1.0.0" remark-lint-no-shell-dollars@"^1.0.0" remark-lint-no-shortcut-reference-image@"^1.0.0" remark-lint-no-shortcut-reference-link@"^1.0.1" remark-lint-no-table-indentation@"^1.0.0" remark-lint-no-tabs@"^1.0.0" remark-lint-no-undefined-references@"^1.0.0" remark-lint-no-unused-definitions@"^1.0.0" remark-lint-ordered-list-marker-style@"^1.0.0" remark-lint-ordered-list-marker-value@"^1.0.0" remark-lint-rule-style@"^1.0.0" remark-lint-strong-marker@"^1.0.0" remark-lint-table-cell-padding@"^1.0.0" remark-lint-table-pipe-alignment@"^1.0.0" remark-lint-table-pipes@"^1.0.0" remark-lint-unordered-list-marker-style@"^1.0.0" remark-slug@"^5.0.0" remark-unlink@"^2.0.0" remark-validate-links@"^9.0.1" remark-vdom@"^8.0.0" semver@"^6.0.0" spdx-license-ids@"^3.0.0" tap-min@"git+https://github.com/Planeshifter/tap-min.git" tap-spec@"5.x.x" tap-summary@"^4.0.0" tap-xunit@"^2.2.0" tape@"git+https://github.com/kgryte/tape.git#fix/globby" to-vfile@"^6.0.0" typedoc@"^0.16.11" uglify-es@"^3.1.1" uglifyify@"^5.0.0" unified-lint-rule@"^1.0.1" unist-util-visit@"^2.0.0" yaml@"^1.0.0"
1+
acorn@"^8.1.0" acorn-loose@"^8.0.2" acorn-walk@"^8.0.2" d3-format@"^1.0.0" d3-scale@"^1.0.0" d3-shape@"^1.0.0" d3-time-format@"^2.0.0" debug@"^2.6.9" glob@"^7.0.5" minimist@"^1.2.0" readable-stream@"^2.1.4" resolve@"^1.1.7" vdom-to-html@"^2.3.0" virtual-dom@"^2.1.1" 0x@"^4.10.2" @commitlint/cli@"^17.4.4" @commitlint/cz-commitlint@"^17.4.4" @kaciras/deasync@"^1.0.1" @types/node@"^13.9.0" ajv@"^5.2.2" browser-pack-flat@"^3.0.0" browserify@"^17.0.0" bundle-collapser@"^1.3.0" c8@"^7.12.0" chai@"^3.5.0" cheerio@"^1.0.0-rc.12" commitizen@"^4.3.0" common-shakeify@"^0.6.0" conventional-changelog-conventionalcommits@"^5.0.0" doctrine@"^3.0.0" dtslint@"^3.3.0" envify@"^4.0.0" eslint@"^8.0.1" eslint-plugin-node@"^11.1.0" factor-bundle@"^2.5.0" gh-pages@"git+https://github.com/Planeshifter/gh-pages.git#main" inquirer@"^8.0.0" jsdoc@"^3.4.0" lunr@"^2.3.9" mathjax-node@"^2.0.1" mathjax-node-sre@"^3.0.0" mkdirp@"^0.5.1" mustache@"^4.0.0" parse-link-header@"^1.0.1" plato@"^1.5.0" process@"^0.11.10" proxyquire@"^2.0.0" proxyquire-universal@"^2.0.0" proxyquireify@"^3.1.1" read-installed@"^4.0.3" rehype@"^9.0.0" rehype-highlight@"^3.0.0" remark@"^11.0.1" remark-cli@"^7.0.0" remark-frontmatter@"^1.2.0" remark-html@"^10.0.0" remark-lint@"^6.0.0" remark-lint-blockquote-indentation@"^1.0.0" remark-lint-checkbox-character-style@"^1.0.0" remark-lint-checkbox-content-indent@"^1.0.0" remark-lint-code-block-style@"^1.0.0" remark-lint-definition-case@"^1.0.0" remark-lint-definition-spacing@"^1.0.0" remark-lint-emphasis-marker@"^1.0.0" remark-lint-fenced-code-flag@"^1.0.0" remark-lint-fenced-code-marker@"^1.0.0" remark-lint-file-extension@"^1.0.0" remark-lint-final-definition@"^1.0.0" remark-lint-final-newline@"^1.0.0" remark-lint-first-heading-level@"^1.1.0" remark-lint-hard-break-spaces@"^1.0.1" remark-lint-heading-increment@"^1.0.0" remark-lint-heading-style@"^1.0.0" remark-lint-linebreak-style@"^1.0.0" remark-lint-link-title-style@"^1.0.0" remark-lint-list-item-bullet-indent@"^1.0.0" remark-lint-list-item-content-indent@"^1.0.0" remark-lint-list-item-indent@"^1.0.0" remark-lint-list-item-spacing@"^1.1.0" remark-lint-maximum-heading-length@"^1.0.0" remark-lint-maximum-line-length@"^1.0.0" remark-lint-no-auto-link-without-protocol@"^1.0.0" remark-lint-no-blockquote-without-marker@"^2.0.0" remark-lint-no-consecutive-blank-lines@"^1.0.0" remark-lint-no-duplicate-definitions@"^1.0.0" remark-lint-no-duplicate-headings@"^1.0.0" remark-lint-no-duplicate-headings-in-section@"^1.0.0" remark-lint-no-emphasis-as-heading@"^1.0.0" remark-lint-no-empty-url@"^1.0.1" remark-lint-no-file-name-articles@"^1.0.0" remark-lint-no-file-name-consecutive-dashes@"^1.0.0" remark-lint-no-file-name-irregular-characters@"^1.0.0" remark-lint-no-file-name-mixed-case@"^1.0.0" remark-lint-no-file-name-outer-dashes@"^1.0.1" remark-lint-no-heading-content-indent@"^1.0.0" remark-lint-no-heading-indent@"^1.0.0" remark-lint-no-heading-like-paragraph@"^1.0.0" remark-lint-no-heading-punctuation@"^1.0.0" remark-lint-no-html@"^1.0.0" remark-lint-no-inline-padding@"^1.0.0" remark-lint-no-literal-urls@"^1.0.0" remark-lint-no-missing-blank-lines@"^1.0.0" remark-lint-no-multiple-toplevel-headings@"^1.0.0" remark-lint-no-paragraph-content-indent@"^1.0.1" remark-lint-no-reference-like-url@"^1.0.0" remark-lint-no-shell-dollars@"^1.0.0" remark-lint-no-shortcut-reference-image@"^1.0.0" remark-lint-no-shortcut-reference-link@"^1.0.1" remark-lint-no-table-indentation@"^1.0.0" remark-lint-no-tabs@"^1.0.0" remark-lint-no-undefined-references@"^1.0.0" remark-lint-no-unused-definitions@"^1.0.0" remark-lint-ordered-list-marker-style@"^1.0.0" remark-lint-ordered-list-marker-value@"^1.0.0" remark-lint-rule-style@"^1.0.0" remark-lint-strong-marker@"^1.0.0" remark-lint-table-cell-padding@"^1.0.0" remark-lint-table-pipe-alignment@"^1.0.0" remark-lint-table-pipes@"^1.0.0" remark-lint-unordered-list-marker-style@"^1.0.0" remark-slug@"^5.0.0" remark-unlink@"^2.0.0" remark-validate-links@"^9.0.1" remark-vdom@"^8.0.0" semver@"^6.0.0" spdx-license-ids@"^3.0.0" tap-min@"git+https://github.com/Planeshifter/tap-min.git" tap-spec@"5.x.x" tap-summary@"^4.0.0" tap-xunit@"^2.2.0" tape@"git+https://github.com/kgryte/tape.git#fix/globby" to-vfile@"^6.0.0" typedoc@"^0.16.11" uglify-es@"^3.1.1" uglifyify@"^5.0.0" unified-lint-rule@"^1.0.1" unist-util-visit@"^2.0.0" yaml@"^1.0.0" node-gyp@"^9.3.1"

lib/node_modules/@stdlib/array/base/assert/docs/types/index.d.ts

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,37 @@
2121
/* tslint:disable:max-line-length */
2222
/* tslint:disable:max-file-line-count */
2323

24+
import contains = require( '@stdlib/array/base/assert/contains' );
2425
import isAccessorArray = require( '@stdlib/array/base/assert/is-accessor-array' );
2526

2627
/**
2728
* Interface describing the `assert` namespace.
2829
*/
2930
interface Namespace {
31+
/**
32+
* Tests if an array contains a provided search value.
33+
*
34+
* @param x - input array
35+
* @param value - search value
36+
* @returns boolean indicating if an array contains a search value
37+
*
38+
* @example
39+
* var x = [ 1, 2, 3 ];
40+
*
41+
* var out = ns.contains( x, 2 );
42+
* // returns true
43+
*
44+
* @example
45+
* var x = [ 1, 2, 3 ];
46+
*
47+
* var fcn = ns.contains.factory( x );
48+
* // returns <Function>
49+
*
50+
* var out = fcn( 2 );
51+
* // returns true
52+
*/
53+
contains: typeof contains;
54+
3055
/**
3156
* Tests if an array-like object supports the accessor (get/set) protocol.
3257
*

lib/node_modules/@stdlib/array/base/docs/types/index.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@ interface Namespace {
250250
/**
251251
* Copies the elements of an array-like object to a new "generic" array.
252252
*
253-
* @param x - array length
253+
* @param x - input array
254254
* @returns output array
255255
*
256256
* @example

lib/node_modules/@stdlib/array/docs/types/index.d.ts

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ import DataView = require( '@stdlib/array/dataview' );
3232
import datespace = require( '@stdlib/array/datespace' );
3333
import arrayDataType = require( '@stdlib/array/dtype' );
3434
import arrayDataTypes = require( '@stdlib/array/dtypes' );
35+
import aempty = require( '@stdlib/array/empty' );
3536
import filledarray = require( '@stdlib/array/filled' );
3637
import filledarrayBy = require( '@stdlib/array/filled-by' );
3738
import Float32Array = require( '@stdlib/array/float32' );
@@ -359,6 +360,44 @@ interface Namespace {
359360
*/
360361
arrayDataTypes: typeof arrayDataTypes;
361362

363+
/**
364+
* Creates an uninitialized array having a specified length.
365+
*
366+
* ## Notes
367+
*
368+
* - In browser environments, the function always returns zero-filled arrays.
369+
* - If `dtype` is `'generic'`, the function always returns a zero-filled array.
370+
* - In Node.js versions `>=3.0.0`, the underlying memory of returned typed arrays is **not** initialized. Memory contents are unknown and may contain **sensitive** data.
371+
*
372+
* The function recognizes the following data types:
373+
*
374+
* - `float64`: double-precision floating-point numbers (IEEE 754)
375+
* - `float32`: single-precision floating-point numbers (IEEE 754)
376+
* - `complex128`: double-precision complex floating-point numbers
377+
* - `complex64`: single-precision complex floating-point numbers
378+
* - `int32`: 32-bit two's complement signed integers
379+
* - `uint32`: 32-bit unsigned integers
380+
* - `int16`: 16-bit two's complement signed integers
381+
* - `uint16`: 16-bit unsigned integers
382+
* - `int8`: 8-bit two's complement signed integers
383+
* - `uint8`: 8-bit unsigned integers
384+
* - `uint8c`: 8-bit unsigned integers clamped to `0-255`
385+
* - `generic`: generic JavaScript values
386+
*
387+
* @param length - array length
388+
* @param dtype - data type (default: 'float64')
389+
* @returns empty array
390+
*
391+
* @example
392+
* var arr = ns.aempty( 2 );
393+
* // returns <Float64Array>
394+
*
395+
* @example
396+
* var arr = ns.aempty( 2, 'float32' );
397+
* // returns <Float32Array>
398+
*/
399+
aempty: typeof aempty;
400+
362401
/**
363402
* Returns a filled typed array view of an `ArrayBuffer`.
364403
*

lib/node_modules/@stdlib/math/base/special/docs/types/index.d.ts

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1848,15 +1848,24 @@ interface Namespace {
18481848
cflipsignf: typeof cflipsignf;
18491849

18501850
/**
1851-
* Rounds a complex number toward negative infinity.
1851+
* Rounds a double-precision complex floating-point number toward negative infinity.
18521852
*
1853-
* @param re - real component
1854-
* @param im - imaginary component
1855-
* @returns real and imaginary components
1853+
* @param z - input value
1854+
* @returns result
18561855
*
18571856
* @example
1858-
* var out = ns.cfloor( 5.5, 3.3 );
1859-
* // returns [ 5.0, 3.0 ]
1857+
* var Complex128 = require( `@stdlib/complex/float64` );
1858+
* var real = require( `@stdlib/complex/real` );
1859+
* var imag = require( `@stdlib/complex/imag` );
1860+
*
1861+
* var v = ns.cfloor( new Complex128( 5.5, 3.3 ) );
1862+
* // returns <Complex128>
1863+
*
1864+
* var re = real( v );
1865+
* // returns 5.0
1866+
*
1867+
* var im = imag( v );
1868+
* // returns 3.0
18601869
*/
18611870
cfloor: typeof cfloor;
18621871

0 commit comments

Comments
 (0)