/nettyfinder

Primary LanguageDartMIT LicenseMIT

This was originally built by Bolaji Ayodeji so all rights goes to him, I only interpreted the javascript code to Dart

Getting started

Add the dependency to your pubspec.yaml

dependencies:
    nettyfinder: <latest-version>

Usage

// Import the package
import 'package:nettyfinder/nettyfinder.dart';  
void main() {

    // This is a callable class
    // Just instantiate the class with the number
  var netFinder = NetworkTypeDetect("+2347012345678");

  // Return null if number is valid but not recognized else throw a descriptive exception
  print('Network Type: ${netFinder() ?? 'Not a recognized number'}');
}

Contribution

Contributions are welcome.