🏄♂️
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(const MainApp()); | |
} | |
class MainApp extends StatelessWidget { | |
const MainApp({super.key}); | |
@override |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(const MainApp()); | |
} | |
class MainApp extends StatelessWidget { | |
const MainApp({super.key}); | |
@override |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(const MainApp()); | |
} | |
class MainApp extends StatelessWidget { | |
const MainApp({super.key}); | |
@override |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// Fancy print utility | |
void fancyPrint(dynamic value, {String label = "Result", String color = ConsoleColors.green}) { | |
print("${color}✨ [$label] => $value${ConsoleColors.reset}"); | |
} | |
/// ANSI color codes | |
class ConsoleColors { | |
static const reset = '\x1B[0m'; | |
static const red = '\x1B[31m'; | |
static const green = '\x1B[32m'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FAILURE: Build failed with an exception. | |
The applied Android Gradle Plugin version (7.3.0) is lower than the minimum supported 7.3.1. | |
or | |
* Where: | |
Build file 'C:\Users\ajas\Videos\cubit\clone\cubit-bloc-flutter-example\cubit_bloc_flutter\android\build.gradle' line: 7 | |
* What went wrong: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Git Commands Cheat Sheet 🚀 | |
## 🔹 Setup Git | |
```bash | |
git config --global user.name "Your Name" | |
git config --global user.email "youremail@example.com" | |
git config --list | |
``` | |
## 🔹 Initialize or Clone Repository |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static Widget customDropdownFormField<T>({ | |
required BuildContext context, | |
required String label, | |
required String hint, | |
required T? value, | |
required List<DropdownMenuItem<T>> items, | |
required Function(T?) onChanged, | |
required String? Function(T?)? validator, | |
}) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main() { | |
WidgetsFlutterBinding.ensureInitialized(); // add this line to fix it | |
runApp(const MyApp()); | |
} | |
// restart emulator | |
// rerun the app |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
enum ValidationType { | |
phoneNumber, | |
panCard, | |
aadharCard, | |
pincode, | |
bankAccount, | |
email, | |
otp, | |
emptyCheck, | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
import 'package:flutter/foundation.dart'; | |
class CommonUtils { | |
CommonUtils._(); | |
static snackbar({required BuildContext context, required String message}) { | |
SnackBar snackBar = SnackBar( | |
// behavior: SnackBarBehavior.floating, | |
content: Text(message), |
NewerOlder