extility 0.1.0

  • Readme
  • Changelog
  • Installing
  • 50

Extility #

A useful collection of static extension methods on basic Dart types. See the examples/ directory for some runnable example usages.

Methods #

Methods are organized below by the type that they extend on. Note that the type headings below aren't necessarily valid syntax, they're just for human consumption.

Comparable

  • genericClamp - clamp any suitable Comparable value

Iterable

  • bracket - add values at the beginning and end of an iterable
  • interleave - insert values between elements of an iterable

Development #

Dead simple if you're accustomed to Dart development. Get dependencies (there are only dev dependencies, by design) with pub get. Run the tests with pub run test.

Please be sure to document any methods you add. Also add them to the readme (above) and to the examples/ directory. Thanks!

dart_dev #

This repository uses dart_dev to simplify developer tooling. This means that the following shortcuts are available. These are also used in CI for consistency. You don't have to do things this way, it's just a helpful option. You do you.

  • pub run dart_dev analyze - run the analyzer
  • pub run dart_dev format - run the formatter
  • pub run dart_dev test - run the tests

Issues #

Please file feature requests and bugs on GitHub.

0.1.0 #

  • Initial version
  • Add Iterable<E>.bracket
  • Add Iterable<E>.interleave
  • Add Comparable<T extends Comparable<T>>.genericClamp

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  extility: ^0.1.0

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter pub get

Alternatively, your editor might support pub get or flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:extility/extility.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
0
Health:
Code health derived from static analysis. [more]
100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
100
Overall:
Weighted score of the above. [more]
50
Learn more about scoring.

We analyzed this package on Apr 7, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.7.1
  • pana: 0.13.6

Maintenance suggestions

Maintain an example.

None of the files in the package's example/ directory matches known example patterns.

Common filename patterns include main.dart, example.dart, and extility.dart. Packages with multiple examples should provide example/README.md.

For more information see the pub package layout conventions.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.6.0 <3.0.0
Dev dependencies
dart_dev ^3.2.1
pedantic ^1.8.0
test ^1.6.0