Skip to content

[FREEZED] Minimalistic plugin that provides country flags through Flutter CustomPainter

License

Notifications You must be signed in to change notification settings

bgoncharuck/no_svg_country_flags

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Null safety Dependencies Except Flutter Backwards Compatibility

No Svg Country Flags

I was shocked to see that every plugin with country flags for Flutter depends on some assets and other plugins like flutter_svg.

Can't understand why load assets if you can use something that is native for flutter like CustomPaint.

dependencies:
  flutter:
    sdk: flutter

That's all!

  • It is simply faster. You don't load anything, you just draw on Flutter Canvas.
  • It weights less. You don't need a plugin with a bunch of logic that does the same I did in every CustomPainter here.
  • It does not have any other dependency except for Flutter. Which is good for clean architecture freaks like me.

Example

const CountryFlag(
  countryCode: 'PL',
  width: 68,
  height: 42,
  borderRadius: 12,
)

About

[FREEZED] Minimalistic plugin that provides country flags through Flutter CustomPainter

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages