is_null 1.0.0+2 icon indicating copy to clipboard operation
is_null: ^1.0.0+2 copied to clipboard

Check null-ness easily

example/is_null_example.dart

import 'package:is_null/is_null.dart';

void main() {
  var thing =
      "Put anything in place of this string (Don't forget to delete the double quotes)";

  print(IsNotNull(thing));

  switch (IsThisNotNull(thing)) {
    case true:
      print('thank goodness it aint null');
      break;
    case false:
      print('damnit, its null!');
  }

  print('Is this causeing an issue? ${IsItNotNull(thing)}');

  dynamic anotherThing = ()=>throw 'told ya to put anything';

  print(IsNull(anotherThing));

  switch (IsThisNull(thing)) {
    case false:
      print('thank goodness it aint null');
      break;
    case true:
      print('damnit, its null!');
  }

  print('Is this causeing an issue? ${IsItNull(thing)}');
}
0
likes
120
pub points
0%
popularity

Publisher

verified publisher iconretarded.tech

Check null-ness easily

Repository (GitHub)

Documentation

API reference

License

Icon for licenses.BSD-3-Clause (LICENSE)

More

Packages that depend on is_null