Skip to content

Commit 6bb3c64

Browse files
committed
docs: update examples in TSDoc comments in utils/async for doctesting
--- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: na - task: lint_package_json status: na - task: lint_repl_help status: na - task: lint_javascript_src status: na - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: passed - task: lint_typescript_tests status: na - task: lint_license_headers status: passed ---
1 parent 3e6159b commit 6bb3c64

File tree

22 files changed

+95
-95
lines changed

22 files changed

+95
-95
lines changed

lib/node_modules/@stdlib/utils/async/any-by-right/docs/types/index.d.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ interface AnyByRightAsync {
260260
* };
261261
*
262262
* // Create a `anyByRightAsync` function which invokes the predicate function for each collection element sequentially:
263-
* var anyByRightAsync = factory( opts, predicate );
263+
* var anyByRight = anyByRightAsync.factory( opts, predicate );
264264
*
265265
* // Create a collection over which to iterate:
266266
* var files = [
@@ -281,7 +281,7 @@ interface AnyByRightAsync {
281281
* }
282282
*
283283
* // Try to read each element in `files`:
284-
* anyByRightAsync( files, done );
284+
* anyByRight( files, done );
285285
*/
286286
factory<T = unknown, V = unknown>( options: Options<T, V>, predicate: Predicate<T, V> ): FactoryFunction<T>;
287287

@@ -313,7 +313,7 @@ interface AnyByRightAsync {
313313
* }
314314
* }
315315
*
316-
* var anyByRightAsync = factory( predicate );
316+
* var anyByRight = anyByRightAsync.factory( predicate );
317317
*
318318
* // Create a collection over which to iterate:
319319
* var files = [
@@ -334,7 +334,7 @@ interface AnyByRightAsync {
334334
* }
335335
*
336336
* // Try to read each element in `files`:
337-
* anyByRightAsync( files, done );
337+
* anyByRight( files, done );
338338
*/
339339
factory<T = unknown, V = unknown>( predicate: Predicate<T, V> ): FactoryFunction<T>;
340340
}

lib/node_modules/@stdlib/utils/async/any-by/docs/types/index.d.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ interface AnyByAsync {
260260
* };
261261
*
262262
* // Create a `anyByAsync` function which invokes the predicate function for each collection element sequentially:
263-
* var anyByAsync = factory( opts, predicate );
263+
* var anyBy = anyByAsync.factory( opts, predicate );
264264
*
265265
* // Create a collection over which to iterate:
266266
* var files = [
@@ -281,7 +281,7 @@ interface AnyByAsync {
281281
* }
282282
*
283283
* // Try to read each element in `files`:
284-
* anyByAsync( files, done );
284+
* anyBy( files, done );
285285
*/
286286
factory<T = unknown, V = unknown>( options: Options<T, V>, predicate: Predicate<T, V> ): FactoryFunction<T>;
287287

@@ -313,7 +313,7 @@ interface AnyByAsync {
313313
* }
314314
* }
315315
*
316-
* var anyByAsync = factory( predicate );
316+
* var anyBy = anyByAsync.factory( predicate );
317317
*
318318
* // Create a collection over which to iterate:
319319
* var files = [
@@ -334,7 +334,7 @@ interface AnyByAsync {
334334
* }
335335
*
336336
* // Try to read each element in `files`:
337-
* anyByAsync( files, done );
337+
* anyBy( files, done );
338338
*/
339339
factory<T = unknown, V = unknown>( predicate: Predicate<T, V> ): FactoryFunction<T>;
340340
}

lib/node_modules/@stdlib/utils/async/bifurcate-by/docs/types/index.d.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ interface BifurcateByAsync {
285285
* };
286286
*
287287
* // Create a `bifurcateByAsync` function which invokes the predicate function for each collection element sequentially:
288-
* var bifurcateByAsync = factory( opts, predicate );
288+
* var bifurcateBy = bifurcateByAsync.factory( opts, predicate );
289289
*
290290
* // Create a collection over which to iterate:
291291
* var files = [
@@ -302,7 +302,7 @@ interface BifurcateByAsync {
302302
* }
303303
*
304304
* // Try to read each element in `files`:
305-
* bifurcateByAsync( files, done );
305+
* bifurcateBy( files, done );
306306
*/
307307
factory<T = unknown, V = unknown>( options: Options<T, V>, predicate: Predicate<T, V> ): FactoryFunction<T>;
308308

@@ -338,7 +338,7 @@ interface BifurcateByAsync {
338338
* };
339339
*
340340
* // Create a `bifurcateByAsync` function which invokes the predicate function for each collection element sequentially:
341-
* var bifurcateByAsync = factory( opts, predicate );
341+
* var bifurcateBy = bifurcateByAsync.factory( opts, predicate );
342342
*
343343
* // Create a collection over which to iterate:
344344
* var files = [
@@ -355,7 +355,7 @@ interface BifurcateByAsync {
355355
* }
356356
*
357357
* // Try to read each element in `files`:
358-
* bifurcateByAsync( files, done );
358+
* bifurcateBy( files, done );
359359
*/
360360
factory<T = unknown, V = unknown>( predicate: Predicate<T, V> ): FactoryFunction<T>;
361361
}

lib/node_modules/@stdlib/utils/async/count-by/docs/types/index.d.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,7 @@ interface CountByAsync {
288288
* };
289289
*
290290
* // Create a `countByAsync` function which invokes the indicator function for each collection element sequentially:
291-
* var countByAsync = factory( opts, indicator );
291+
* var countBy = countByAsync.factory( opts, indicator );
292292
*
293293
* // Create a collection over which to iterate:
294294
* var files = [
@@ -305,7 +305,7 @@ interface CountByAsync {
305305
* }
306306
*
307307
* // Try to read each element in `files`:
308-
* countByAsync( files, done );
308+
* countBy( files, done );
309309
*/
310310
factory<T = unknown, V = unknown>( options: Options<T, V>, indicator: Indicator<T, V> ): FactoryFunction<T>;
311311

@@ -342,7 +342,7 @@ interface CountByAsync {
342342
* }
343343
*
344344
* // Create a `countByAsync` function which invokes the indicator function for each collection element sequentially:
345-
* var countByAsync = factory( indicator );
345+
* var countBy = countByAsync.factory( indicator );
346346
*
347347
* // Create a collection over which to iterate:
348348
* var files = [
@@ -359,7 +359,7 @@ interface CountByAsync {
359359
* }
360360
*
361361
* // Try to read each element in `files`:
362-
* countByAsync( files, done );
362+
* countBy( files, done );
363363
*/
364364
factory<T = unknown, V = unknown>( indicator: Indicator<T, V> ): FactoryFunction<T>;
365365
}

lib/node_modules/@stdlib/utils/async/every-by-right/docs/types/index.d.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ interface EveryByRightAsync {
261261
* };
262262
*
263263
* // Create an `everyByRightAsync` function which invokes the predicate function for each collection element sequentially:
264-
* var everyByRightAsync = factory( opts, predicate );
264+
* var everyByRight = everyByRightAsync.factory( opts, predicate );
265265
*
266266
* // Create a collection over which to iterate:
267267
* var files = [
@@ -282,7 +282,7 @@ interface EveryByRightAsync {
282282
* }
283283
*
284284
* // Try to read each element in `files`:
285-
* everyByRightAsync( files, done );
285+
* everyByRight( files, done );
286286
*/
287287
factory<T = unknown, V = unknown>( options: Options<T, V>, predicate: Predicate<T, V> ): FactoryFunction<T>;
288288

@@ -320,7 +320,7 @@ interface EveryByRightAsync {
320320
* };
321321
*
322322
* // Create an `everyByRightAsync` function which invokes the predicate function for each collection element sequentially:
323-
* var everyByRightAsync = factory( opts, predicate );
323+
* var everyByRight = everyByRightAsync.factory( opts, predicate );
324324
*
325325
* // Create a collection over which to iterate:
326326
* var files = [
@@ -341,7 +341,7 @@ interface EveryByRightAsync {
341341
* }
342342
*
343343
* // Try to read each element in `files`:
344-
* everyByRightAsync( files, done );
344+
* everyByRight( files, done );
345345
*/
346346
factory<T = unknown, V = unknown>( predicate: Predicate<T, V> ): FactoryFunction<T>;
347347
}

lib/node_modules/@stdlib/utils/async/every-by/docs/types/index.d.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ interface EveryByAsync {
261261
* };
262262
*
263263
* // Create an `everyByAsync` function which invokes the predicate function for each collection element sequentially:
264-
* var everyByAsync = factory( opts, predicate );
264+
* var everyBy = everyByAsync.factory( opts, predicate );
265265
*
266266
* // Create a collection over which to iterate:
267267
* var files = [
@@ -282,7 +282,7 @@ interface EveryByAsync {
282282
* }
283283
*
284284
* // Try to read each element in `files`:
285-
* everyByAsync( files, done );
285+
* everyBy( files, done );
286286
*/
287287
factory<T = unknown, V = unknown>( options: Options<T, V>, predicate: Predicate<T, V> ): FactoryFunction<T>;
288288

@@ -320,7 +320,7 @@ interface EveryByAsync {
320320
* };
321321
*
322322
* // Create an `everyByAsync` function which invokes the predicate function for each collection element sequentially:
323-
* var everyByAsync = factory( opts, predicate );
323+
* var everyBy = everyByAsync.factory( opts, predicate );
324324
*
325325
* // Create a collection over which to iterate:
326326
* var files = [
@@ -341,7 +341,7 @@ interface EveryByAsync {
341341
* }
342342
*
343343
* // Try to read each element in `files`:
344-
* everyByAsync( files, done );
344+
* everyBy( files, done );
345345
*/
346346
factory<T = unknown, V = unknown>( predicate: Predicate<T, V> ): FactoryFunction<T>;
347347
}

lib/node_modules/@stdlib/utils/async/for-each-right/docs/types/index.d.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ interface ForEachRightAsync {
258258
* };
259259
*
260260
* // Create a `forEachRightAsync` function which invokes `read` for each collection element sequentially:
261-
* var forEachRightAsync = factory( opts, read );
261+
* var forEachRight = forEachRightAsync.factory( opts, read );
262262
*
263263
* // Create a collection over which to iterate:
264264
* var files = [
@@ -275,7 +275,7 @@ interface ForEachRightAsync {
275275
* }
276276
*
277277
* // Run `read` for each element in `files`:
278-
* forEachRightAsync( files, done );
278+
* forEachRight( files, done );
279279
*/
280280
factory<T = unknown, V = unknown>( options: Options<T, V>, fcn: Fcn<T, V> ): FactoryFunction;
281281

@@ -309,7 +309,7 @@ interface ForEachRightAsync {
309309
* }
310310
*
311311
* // Create a `forEachRightAsync` function which invokes `read` for each collection element sequentially:
312-
* var forEachRightAsync = factory( read );
312+
* var forEachRight = forEachRightAsync.factory( read );
313313
*
314314
* // Create a collection over which to iterate:
315315
* var files = [
@@ -326,7 +326,7 @@ interface ForEachRightAsync {
326326
* }
327327
*
328328
* // Run `read` for each element in `files`:
329-
* forEachRightAsync( files, done );
329+
* forEachRight( files, done );
330330
*/
331331
factory<T = unknown, V = unknown>( fcn: Fcn<T, V> ): FactoryFunction;
332332
}

lib/node_modules/@stdlib/utils/async/for-each/docs/types/index.d.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ interface ForEachAsync {
258258
* };
259259
*
260260
* // Create a `forEachAsync` function which invokes `read` for each collection element sequentially:
261-
* var forEachAsync = factory( opts, read );
261+
* var forEach = forEachAsync.factory( opts, read );
262262
*
263263
* // Create a collection over which to iterate:
264264
* var files = [
@@ -275,7 +275,7 @@ interface ForEachAsync {
275275
* }
276276
*
277277
* // Run `read` for each element in `files`:
278-
* forEachAsync( files, done );
278+
* forEach( files, done );
279279
*/
280280
factory<T = unknown, V = unknown>( options: Options<T, V>, fcn: Fcn<T, V> ): FactoryFunction;
281281

@@ -309,7 +309,7 @@ interface ForEachAsync {
309309
* }
310310
*
311311
* // Create a `forEachAsync` function which invokes `read` for each collection element sequentially:
312-
* var forEachAsync = factory( read );
312+
* var forEach = forEachAsync.factory( read );
313313
*
314314
* // Create a collection over which to iterate:
315315
* var files = [
@@ -326,7 +326,7 @@ interface ForEachAsync {
326326
* }
327327
*
328328
* // Run `read` for each element in `files`:
329-
* forEachAsync( files, done );
329+
* forEach( files, done );
330330
*/
331331
factory<T = unknown, V = unknown>( fcn: Fcn<T, V> ): FactoryFunction;
332332
}

lib/node_modules/@stdlib/utils/async/group-by/docs/types/index.d.ts

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ type ValuesBinary<T> = ( error: Error | null, result: ValuesResults<T> ) => void
128128
* @param error - encountered error or null
129129
* @param result - group results
130130
*/
131-
type IndicesBinary<T> = ( error: Error | null, result: IndicesResults ) => void;
131+
type IndicesBinary = ( error: Error | null, result: IndicesResults ) => void;
132132

133133
/**
134134
* Callback invoked either upon processing all collection elements or upon encountering an error.
@@ -152,7 +152,7 @@ type ValuesCallback<T> = Nullary | Unary | ValuesBinary<T>;
152152
* @param error - encountered error or null
153153
* @param result - group results
154154
*/
155-
type IndicesCallback<T> = Nullary | Unary | IndicesBinary<T>;
155+
type IndicesCallback = Nullary | Unary | IndicesBinary;
156156

157157
/**
158158
* Callback invoked either upon processing all collection elements or upon encountering an error.
@@ -241,7 +241,7 @@ type ValuesFactoryFunction<T> = ( collection: Collection<T>, done: ValuesCallbac
241241
* @param collection - input collection
242242
* @param done - function to invoke upon completion
243243
*/
244-
type IndicesFactoryFunction<T> = ( collection: Collection<T>, done: IndicesCallback<T> ) => void;
244+
type IndicesFactoryFunction<T> = ( collection: Collection<T>, done: IndicesCallback ) => void;
245245

246246
/**
247247
* Invokes an indicator function for each element in a collection.
@@ -303,7 +303,7 @@ interface GroupByAsync {
303303
*
304304
* groupByAsync( files, {}, indicator, done );
305305
*/
306-
<T = unknown, V = unknown>( collection: Collection<T>, options: IndicesOptions<T, V>, indicator: Indicator<T, V>, done: IndicesCallback<T> ): void;
306+
<T = unknown, V = unknown>( collection: Collection<T>, options: IndicesOptions<T, V>, indicator: Indicator<T, V>, done: IndicesCallback ): void;
307307

308308
/**
309309
* Groups values according to an indicator function.
@@ -487,7 +487,7 @@ interface GroupByAsync {
487487
* };
488488
*
489489
* // Create a `groupByAsync` function which invokes the indicator function for each collection element sequentially:
490-
* var groupByAsync = factory( opts, indicator );
490+
* var groupBy = groupByAsync.factory( opts, indicator );
491491
*
492492
* // Create a collection over which to iterate:
493493
* var files = [
@@ -504,7 +504,7 @@ interface GroupByAsync {
504504
* }
505505
*
506506
* // Try to read each element in `files`:
507-
* groupByAsync( files, done );
507+
* groupBy( files, done );
508508
*/
509509
factory<T = unknown, V = unknown>( options: IndicesOptions<T, V>, indicator: Indicator<T, V> ): IndicesFactoryFunction<T>;
510510

@@ -546,7 +546,7 @@ interface GroupByAsync {
546546
* };
547547
*
548548
* // Create a `groupByAsync` function which invokes the indicator function for each collection element sequentially:
549-
* var groupByAsync = factory( opts, indicator );
549+
* var groupBy = groupByAsync.factory( opts, indicator );
550550
*
551551
* // Create a collection over which to iterate:
552552
* var files = [
@@ -563,7 +563,7 @@ interface GroupByAsync {
563563
* }
564564
*
565565
* // Try to read each element in `files`:
566-
* groupByAsync( files, done );
566+
* groupBy( files, done );
567567
*/
568568
factory<T = unknown, V = unknown>( options: IndicesAndValuesOptions<T, V>, indicator: Indicator<T, V> ): IndicesAndValuesFactoryFunction<T>;
569569

@@ -605,7 +605,7 @@ interface GroupByAsync {
605605
* };
606606
*
607607
* // Create a `groupByAsync` function which invokes the indicator function for each collection element sequentially:
608-
* var groupByAsync = factory( opts, indicator );
608+
* var groupBy = groupByAsync.factory( opts, indicator );
609609
*
610610
* // Create a collection over which to iterate:
611611
* var files = [
@@ -622,7 +622,7 @@ interface GroupByAsync {
622622
* }
623623
*
624624
* // Try to read each element in `files`:
625-
* groupByAsync( files, done );
625+
* groupBy( files, done );
626626
*/
627627
factory<T = unknown, V = unknown>( options: ValuesOptions<T, V> | BaseOptions<T, V>, indicator: Indicator<T, V> ): ValuesFactoryFunction<T>;
628628

@@ -654,7 +654,7 @@ interface GroupByAsync {
654654
* }
655655
*
656656
* // Create a `groupByAsync` function which invokes the indicator function for each collection element sequentially:
657-
* var groupByAsync = factory( indicator );
657+
* var groupBy = groupByAsync.factory( indicator );
658658
*
659659
* // Create a collection over which to iterate:
660660
* var files = [
@@ -671,7 +671,7 @@ interface GroupByAsync {
671671
* }
672672
*
673673
* // Try to read each element in `files`:
674-
* groupByAsync( files, done );
674+
* groupBy( files, done );
675675
*/
676676
factory<T = unknown, V = unknown>( indicator: Indicator<T, V> ): ValuesFactoryFunction<T>;
677677
}

0 commit comments

Comments
 (0)