unities_helper 1.0.0 copy "unities_helper: ^1.0.0" to clipboard
unities_helper: ^1.0.0 copied to clipboard

outdated

A library to help you convert unities and a few other things

example/unities_helper_example.dart

import 'package:unities_helper/unities_helper.dart';

void main() {
  final temperature = convert<Temperature>(
    Temperature.celcius, // from
    Temperature.fahrenheit, // to
    25, // celcius
  ); /// Convert 25°C into Fahrenheit
  print(temperature);
  final length = convert<Length>(
    Length.centimeter, // from
    Length.meter, // to
    300, // centimeters
  ); /// Convert 300 centimeters into meter
  print(length);
  final binary = convert<Binary>( 
    Binary.from, // from text
    Binary.to.withSeparator(' '), // to binary
    // to do binary to text just invert
    'Convert this to binary', // text
  ); /// Convert a text to binary
  print(binary);
}
5
likes
0
pub points
44%
popularity

Publisher

unverified uploader

A library to help you convert unities and a few other things

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

More

Packages that depend on unities_helper