call method

List<File> call({
  1. String directory = 'lib',
})

Gets all the Dart files for the given directory

Implementation

List<File> call({
  String directory = 'lib',
}) {
  final directoryToCheck = Directory(directory);
  return directoryToCheck
      .listSync(recursive: true)
      .whereType<File>()
      .where((file) => file.path.endsWith('.dart'))
      .toList();
}