my_responsive_ui 1.0.3+4 copy "my_responsive_ui: ^1.0.3+4" to clipboard
my_responsive_ui: ^1.0.3+4 copied to clipboard

A Flutter package for creating responsive UIs with easy to use extensions and utilities.

My Responsive UI #

A Flutter package that makes it easy to create responsive UIs across different screen sizes.

Features #

  • Easy to use extensions for responsive dimensions (.h, .w, .sp, .r).
  • Built-in spacing utilities (vs, hs).
  • Safe dimension calculations with min/max boundaries.
  • Orientation change support.
  • Memory leak prevention
  • Support for portrait mode.
  • Responsive layout based on screen size.
  • Support for screen size adaptation on both iOS and Android platforms.

Getting started #

Add this to your package's pubspec.yaml file:

dependencies:
  my_responsive_ui: [current version]

Usage #

  1. Wrap your app with ResponsiveInitializer:
void main() {
  runApp(
    MaterialApp(
      home: ResponsiveInitializer(
        baseHeight: 812, // Design height
        baseWidth: 375,  // Design width
        child: MyApp(),
      ),
    ),
  );
}
  1. Use responsive extensions:
Container(
  height: 200.h,  // Responsive height
  width: 300.w, // Responsive width
  padding: EdgeInsets.all(16.r),
  child: Text(
    'Hello',
    style: TextStyle(fontSize: 16.sp),
  ),
)
  1. Use spacing utilities:
Column(
  children: [
    Text('First'),
    vs(20),  // Vertical space
    Text('Second'),
  ],
)

Socials #

If you have any feedback, suggestions, or issues, feel free to contact us. Your thoughts are highly appreciated.

LinkedIn Telegram Facebook

2
likes
160
points
0
downloads

Publisher

unverified uploader

Weekly Downloads

A Flutter package for creating responsive UIs with easy to use extensions and utilities.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

flutter

More

Packages that depend on my_responsive_ui