array_playground 0.0.4+4 copy "array_playground: ^0.0.4+4" to clipboard
array_playground: ^0.0.4+4 copied to clipboard

Useful extensions for Lists

array_playground #

Useful extensions for Lists

Hecho en 🇵🇷 por Radamés J. Valentín Reyes

Import #

import 'package:array_playground/array_playground.dart';

AsyncRemoveWhere #

An async function to remove all items where the function's criteria isn't met.

List<int> dataArray = [15,18,11,25,63];
print("Original array:");
print(dataArray);
await dataArray.asyncRemoveWhere((a)async{
  return (15 < a && a <= 25);
});
print("Resulting array:");
print(dataArray);

Chunkify array #

List<int> dataArray = [15,18,11,25,63];
List<List> chunkifiedArray = dataArray.chunkify(2);
print(chunkifiedArray);//Output [[15, 18], [11, 25], [63]]

Contribute/donate by tapping on the Pay Pal logo/image #


0
likes
110
pub points
0%
popularity

Publisher

unverified uploader

Useful extensions for Lists

Documentation

API reference

License

MIT (LICENSE)

More

Packages that depend on array_playground