zeba_academy_extensions 1.0.0
zeba_academy_extensions: ^1.0.0 copied to clipboard
Collection of useful Flutter and Dart extensions.
Zeba Academy Extensions #
A comprehensive collection of Flutter and Dart extensions that simplify everyday development.
zeba_academy_extensions provides a rich set of production-ready extension methods for strings, widgets, numbers, dates, collections, nullable values, colors, and more.
⨠Features #
š String Extensions #
- Capitalize first letter
- Capitalize every word
- Reverse string
- Remove spaces
- Repeat string
- Email validation
- Phone validation
- URL validation
- Numeric validation
- Blank string detection
š DateTime Extensions #
- Format dates
- Check today
- Check yesterday
- Calculate age
- Difference from now
ā± Duration Extensions #
- HH:mm:ss formatter
š¢ Number Extensions #
- Currency formatting
- Decimal formatting
- Compact formatting (1K, 1M)
šØ Widget Extensions #
- Padding
- Center
- Expanded
- Flexible
- SizedBox
- Card wrapper
š± BuildContext Extensions #
- Theme
- TextTheme
- Screen width
- Screen height
- Screen size
š Iterable Extensions #
- firstOrNull
- lastOrNull
š List Extensions #
- Separate items with custom separator
šÆ Boolean Extensions #
- Yes / No
- Integer conversion
š Color Extensions #
- Lighten color
- Darken color
ā Validation Extensions #
- Strong password validation
- OTP validation
š” Null Safety Extensions #
- isNullOrEmpty
- orEmpty
Installation #
Add the dependency to your pubspec.yaml.
dependencies:
zeba_academy_extensions: ^1.0.0
Then install packages.
flutter pub get
Import #
import 'package:zeba_academy_extensions/zeba_academy_extensions.dart';
Usage #
String Extensions #
print("hello".capitalize);
// Hello
print("hello world".capitalizeWords);
// Hello World
print("Flutter".reverse);
// rettulF
print("abc@gmail.com".isEmail);
// true
print("9876543210".isPhone);
// true
print("123".isNumeric);
// true
print("Hello World".removeSpaces);
// HelloWorld
DateTime Extensions #
final now = DateTime.now();
print(now.format());
print(now.isToday);
print(now.differenceFromNow());
Number Extensions #
print(250000.currency);
print(1234.decimal);
print(1200000.compact);
Widget Extensions #
Text("Hello")
.paddingAll(16)
.center();
Container()
.card();
Text("Flutter")
.expanded();
BuildContext Extensions #
context.width;
context.height;
context.theme;
context.textTheme;
Nullable Extensions #
String? name;
print(name.isNullOrEmpty);
print(name.orEmpty);
Validation Extensions #
print("Password123".isPasswordStrong);
print("123456".isOTP);
Color Extensions #
Colors.blue.lighten();
Colors.red.darken();
Iterable Extensions #
final numbers = [1, 2, 3];
numbers.firstOrNull;
numbers.lastOrNull;
Boolean Extensions #
true.yesNo;
false.intValue;
Platform Support #
| Platform | Supported |
|---|---|
| Android | ā |
| iOS | ā |
| Web | ā |
| Windows | ā |
| macOS | ā |
| Linux | ā |
Why Zeba Academy Extensions? #
- Lightweight
- Zero unnecessary dependencies
- Null-safe
- Flutter-friendly
- Easy to use
- Production-ready
- Clean API
- Well documented
- Tested
- Cross-platform
Roadmap #
- More String utilities
- Navigation helpers
- Responsive extensions
- Animation helpers
- Theme extensions
- File extensions
- JSON extensions
- Map utilities
- Responsive helpers
- Additional validation methods
Contributing #
Contributions are welcome!
If you find a bug or have a feature request, please open an issue or submit a pull request.
- Fork the repository
- Create a feature branch
- Commit your changes
- Push your branch
- Open a Pull Request
License #
This project is licensed under the GNU General Public License v3.0 (GPL-3.0).
See the LICENSE file for details.
About Me #
⨠Iām Sufyan bin Uzayr, an open-source developer passionate about building and sharing meaningful projects.
You can learn more about me and my work at https://sufyanism.com/ or connect with me on LinkedIn:
https://www.linkedin.com/in/sufyanism
Your all-in-one learning hub! #
š Explore courses and resources in coding, tech, and development at Zeba Academy.
Empower yourself with practical skills through curated tutorials, real-world projects, and hands-on experience.
Level up your tech journey today!
š Links #
Website
Learning Portal
YouTube
https://www.youtube.com/@zeba.academy
https://www.instagram.com/zeba.academy/
Support #
If you find this package useful, consider:
- ā Starring the repository
- š Liking and sharing
- š Reporting issues
- š” Suggesting new features
- š¤ Contributing to development
Made with ā¤ļø by Zeba Academy