bloc_implementation 1.1.4 copy "bloc_implementation: ^1.1.4" to clipboard
bloc_implementation: ^1.1.4 copied to clipboard

A easy and simple Implementation of the BLoC (Business Logic Component) Pattern in Flutter / Dart

example/main.dart

library bloc_implementation;

import 'package:bloc_implementation/bloc_implementation.dart' show BlocParent;

import 'package:flutter/material.dart';

import 'blocs/main_bloc.dart';
import 'screens/homescreen.dart';

void main(List<String> args) {
  runApp(const ExampleApp());
}

class ExampleApp extends StatefulWidget {
  const ExampleApp({Key? key}) : super(key: key);

  @override
  State<ExampleApp> createState() => _ExampleAppState();
}

class _ExampleAppState extends State<ExampleApp> {
  @override
  Widget build(BuildContext context) {
    return BlocParent(
      bloc: MainBloc(),
      child: const MaterialApp(
        home: Homescreen(),
      ),
    );
  }
}
2
likes
160
points
31
downloads

Publisher

verified publisherjulianschumacher.dev

Weekly Downloads

A easy and simple Implementation of the BLoC (Business Logic Component) Pattern in Flutter / Dart

Repository (GitHub)
View/report issues

Documentation

API reference

License

Apache-2.0 (license)

Dependencies

flutter

More

Packages that depend on bloc_implementation