Skip to content

Instantly share code, notes, and snippets.

pdslly

Block or report user

Report or block pdslly

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View dart_futures_02.dart
RaisedButton(
onPressed: () {
final myFuture = http.get('https://my.image.url');
myFuture.then((resp) {
setImage(resp);
});
},
child: Text('Click me!'),
)
View dart_futures_01.dart
final myFuture = http.get(""https://example.com);
// 许多的Dart异步API都是返回的Futures.
You can’t perform that action at this time.