Skip to content

Commit 2a59f98

Browse files
committed
refactor: use predefined types
1 parent 8e5acd2 commit 2a59f98

File tree

1 file changed

+4
-8
lines changed
  • lib/node_modules/@stdlib/array/base/flatten2d/docs/types

1 file changed

+4
-8
lines changed

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

+4-8
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,8 @@
2020

2121
/// <reference types="@stdlib/types"/>
2222

23-
import { Collection } from '@stdlib/types/array';
24-
25-
/**
26-
* Two-dimensional nested array.
27-
*/
28-
type Array2D<T> = Array<Collection<T>>;
23+
import { Collection, Array2D } from '@stdlib/types/array';
24+
import { Shape2D } from '@stdlib/types/ndarray';
2925

3026
/**
3127
* Interface describing `flatten2d`.
@@ -55,7 +51,7 @@ interface Flatten2d {
5551
* var out = flatten2d( x, [ 2, 2 ], true );
5652
* // returns [ 1, 3, 2, 4 ]
5753
*/
58-
<T = unknown>( x: Array2D<T>, shape: Collection<number>, colexicographic: boolean ): Array<T>;
54+
<T = unknown>( x: Array2D<T>, shape: Shape2D, colexicographic: boolean ): Array<T>;
5955

6056
/**
6157
* Flattens a two-dimensional nested array and assigns elements to a provided output array.
@@ -88,7 +84,7 @@ interface Flatten2d {
8884
* var out = flatten2d.assign( x, [ 2, 2 ], true, new Float64Array( 4 ), 1, 0 );
8985
* // returns <Float64Array>[ 1, 3, 2, 4 ]
9086
*/
91-
assign<T = unknown, U = unknown>( x: Array2D<T>, shape: Collection<number>, colexicographic: boolean, out: Collection<U>, stride: number, offset: number ): Collection<T | U>;
87+
assign<T = unknown, U = unknown>( x: Array2D<T>, shape: Shape2D, colexicographic: boolean, out: Collection<U>, stride: number, offset: number ): Collection<T | U>;
9288
}
9389

9490
/**

0 commit comments

Comments
 (0)