flutter_static_utility 1.0.2 copy "flutter_static_utility: ^1.0.2" to clipboard
flutter_static_utility: ^1.0.2 copied to clipboard

Flutter static utilities (email/nickname/phoneNumber .. regex, timeAgo, thousand to K)

example/example.dart

import 'package:flutter/material.dart';
import 'package:flutter_static_utility/flutter_static_utility.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Example',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: const ExamplePage(),
    );
  }
}

class ExamplePage extends StatelessWidget {
  const ExamplePage({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: const Text('Example'),
      ),
      body: Container(
        margin: const EdgeInsets.symmetric(horizontal: 16, vertical: 16),
        child: Center(
          child: Column(
            mainAxisSize: MainAxisSize.min,
            children: <Widget>[
              const Text('3000', style: TextStyle(color: Colors.black),),
              Text(thousandToData(3000).data as String, style: const TextStyle(color: Colors.black),),
            ],
          ),
        ),
      ),

    );
  }
}
1
likes
150
pub points
29%
popularity

Publisher

verified publishertyrannoapartment.com

Flutter static utilities (email/nickname/phoneNumber .. regex, timeAgo, thousand to K)

Homepage
Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

Dependencies

flutter

More

Packages that depend on flutter_static_utility