mvu_layer 0.3.3 copy "mvu_layer: ^0.3.3" to clipboard
mvu_layer: ^0.3.3 copied to clipboard

An Elm-inspired state management for leveraging benefits from the Elm architecture while still being Dart friendly.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:mvu_layer/mvu.dart';

import './page/counter/update.dart';
import './page/input_text/update.dart';

import './page/update.dart';
import './page/view.dart';

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

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
        visualDensity: VisualDensity.adaptivePlatformDensity,
      ),
      home: Card(
        child: CounterProvider(
          child: MVUProvider.fromProcessor(
            processor: InputTextProcessor(),
            child: MVUBuilder(init: init, update: update, view: view),
          ),
        ),
      ),
    );
  }
}
4
likes
150
pub points
52%
popularity

Publisher

unverified uploader

An Elm-inspired state management for leveraging benefits from the Elm architecture while still being Dart friendly.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

async, flutter

More

Packages that depend on mvu_layer