link_checker 4.0.2 copy "link_checker: ^4.0.2" to clipboard
link_checker: ^4.0.2 copied to clipboard

Can find links and check if they're dead in almost any type of file

example/main.dart

import 'package:link_checker/link_checker.dart';
import 'package:test/test.dart';

void main() {
  test('project for dead links', () async {
    var badLinks = <BadLink>[];
    await for (BadLink badLink in getBadLinksInDirectory(blacklistedFilePaths: [
      '.packages',
      'pubspec.lock'
    ], blacklistedDirectories: [
      BlacklistedDirectory('test'),
      BlacklistedDirectory('example'),
      BlacklistedDirectory('.dart_tool')
    ], blacklistedLinks: [
      'http://schemas.android.com'
    ])) {
      badLinks.add(badLink);
    }
    expect(badLinks, isEmpty);
  }, timeout: Timeout.none);
}
0
likes
40
pub points
0%
popularity

Publisher

unverified uploader

Can find links and check if they're dead in almost any type of file

Repository (GitHub)
View/report issues

License

MIT (LICENSE)

Dependencies

markdown

More

Packages that depend on link_checker