flustars 0.0.8 copy "flustars: ^0.0.8" to clipboard
flustars: ^0.0.8 copied to clipboard

outdated

Flutter common utils library. SpUtil, ScreenUtil, WidgetUtil.

example/lib/main.dart

import 'package:common_utils/common_utils.dart';
import 'package:flustars/flustars.dart';
import 'package:flutter/material.dart';

void main() => runApp(new MyApp());

class MyApp extends StatefulWidget {
  @override
  _MyAppState createState() => new _MyAppState();
}

class _MyAppState extends State<MyApp> {
  @override
  void initState() {
    super.initState();
    test();
  }

  void test() async {
    SpUtil spUtil = await SpUtil.getInstance();
    //SpUtil.remove("username");
    SpUtil.putString("username", "sky224");
    LogUtil.e("username: " + SpUtil.getString("username").toString());
  }

  @override
  Widget build(BuildContext context) {
    return new MaterialApp(
      home: new Scaffold(
        appBar: new AppBar(
          title: const Text('Plugin example app'),
        ),
        body: new Center(
          child: new Text('Running on: '),
        ),
      ),
    );
  }
}
86
likes
0
pub points
94%
popularity

Publisher

unverified uploader

Flutter common utils library. SpUtil, ScreenUtil, WidgetUtil.

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

common_utils, flutter, shared_preferences, synchronized

More

Packages that depend on flustars