setup 0.0.5 setup: ^0.0.5 copied to clipboard
Setup - A Progressive reactivity framework. An approachable, performant, and versatile framework for building Flutter user interfaces.
import 'package:flutter/material.dart';
import 'package:setup/setup.dart';
void main() {
runApp(const CounterApp());
}
class CounterApp extends SetupWidget {
const CounterApp();
@override
Widget Function() setup() {
final count = ref(0);
void increment() => count.value++;
return () {
return MaterialApp(
home: Scaffold(
body: Center(child: Text('Count: ${count.value}')),
floatingActionButton: FloatingActionButton(
onPressed: increment,
child: Icon(Icons.plus_one),
),
),
);
};
}
}