自带的:
单一
class DataBloc { StreamController dataBloc = StreamController(); StreamSink get dataSink => dataBloc.sink; }
addData(){ dataBloc.dataSink.add('addsfdb'); }
StreamBuilder( stream: dataBloc.dataBloc.stream, builder: (context, snapshot){ if(snapshot.hasData){ return Text('${snapshot.data}'); }else{ return Text('first'); } }, ),
多次