DEV Community

Discussion on: Explain Futures and Streams in Dart like I'm Five

allanjeremy profile image
Allan N Jeremy Author

Great, thanks. Understood Futures from the promises example. I really didn't get streams until the last sentence.

Still trying to grasp how I'd use them based on your explanation. So do streams generally take futures as values? Or how exactly do they work?

Going by

whenever something of interest is available, it will be passed through the Stream.

Wouldn't a future just work equally as well? I may be a little confused here. I can see use cases for futures, but still confused on how or when I'd need a stream. Do you mind giving an example use-case in production?