fluttercommunity / fluttercommunity/flutter-styleguide

Use SizedBox() as a no-op

Open
#5 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
No language data
Stars
56
Forks
3
PR merge metrics
No merged PRs in 30d

Description

When you don't want to show a "nothing", render a SizedBox().

For instance,

if (snapshot.connectionState == ConnectionState.none) {
return const SizedBox();
} else if (snapshot.hasData) {
return someOtherWidgets;
}

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.