Flutter : Bad state: Stream has already been listened to

前端 未结 11 1334
灰色年华
灰色年华 2020-12-03 04:21

    class MyPage extends StatelessWidget {
      @override
      Widget build(BuildContext context) {
        return Defaul         


        
11条回答
  •  温柔的废话
    2020-12-03 04:42

    For those of you running into this while doing Future.asStream(), you'll need Future.asStream().shareReplay(maxSize: 1) to make it a broadcast/hot stream.

提交回复
热议问题