apco_utils 0.0.1 apco_utils: ^0.0.1 copied to clipboard
Andishe Pardaz Utilities to formating and converting date for Flutter
import 'package:flutter/material.dart';
import 'package:apco_utils/apco_utils.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatefulWidget {
@override
_MyAppState createState() => _MyAppState();
}
class _MyAppState extends State<MyApp> {
@override
void initState() {
super.initState();
}
// Platform messages are asynchronous, so we initialize in an async method.
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(
title: const Text('APCO Utils Tester'),
),
body: Center(
child: Text("Current Time Is : " +
ApcoUtils.formatDateTime(DateTime.now(), 0) +
"\nCurrent Time Is : " +
ApcoUtils.formatDateTime(DateTime.now(), 1) +
"\nCurrent Time Is : " +
ApcoUtils.formatDateTime(DateTime.now(), 2) +
"\nCurrent Time Is : " +
ApcoUtils.formatDateTime(DateTime.now(), 3) +
"\nCurrent Time Is : " +
ApcoUtils.formatDateTime(DateTime.now(), 4) +
"\nCurrent Time Is : " +
ApcoUtils.formatDateTime(DateTime.now(), 5)),
),
),
);
}
}