- Начать писать логику непосредственно в
mapEventToState,
он у вас быстренько превратится в нечитаемую портянку и придете жаловаться на бойлерплейт.
Если правильно готовить блок, то бойлерплейтом там и не пахнет,
эвенты + стейты + блок умещаются все вместе на 1-2 экранах.
Все запредельно воздушно, даже не надо создавать отдельные файлы под эвенты и стейты.
Все ультра емко получается.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import org.apache.kafka.clients.producer.KafkaProducer; | |
| import org.apache.kafka.clients.producer.ProducerConfig; | |
| import org.apache.kafka.clients.producer.ProducerRecord; | |
| import org.apache.kafka.common.Metric; | |
| import org.apache.kafka.common.MetricName; | |
| import java.util.Map; | |
| import java.util.Properties; | |
| import java.util.WeakHashMap; | |
| import java.util.concurrent.ConcurrentLinkedQueue; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * GET SUPER PROVIDER XXL | |
| * From GetX Architects and for GetX Architects | |
| * with L<3VE | |
| * | |
| * https://gist.github.com/PlugFox/fa6ff53257c7bd8edb11ebc2fe889d8e | |
| * https://dartpad.dev/fa6ff53257c7bd8edb11ebc2fe889d8e | |
| */ | |
| /// SUPER LIBRARY: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * https://dartpad.dev/?null_safety=true&id=6f13157effce2c1a525f8355dc35b0cc | |
| * https://gist.github.com/PlugFox/6f13157effce2c1a525f8355dc35b0cc/ | |
| */ | |
| import 'dart:async'; | |
| import 'package:flutter/material.dart'; | |
| void main() => runZonedGuarded( |