Flutter Dev | Uzbekistan 🇺🇿
397 subscribers
574 photos
68 videos
25 files
401 links
Flutter bu - hozirgi kundagi eng yetuk kross platformali dasturlash vositasidir!

Bu kanal Flutterning o'zbek zabon vakillari uchun.

Blog avtori:
© Muhammad Aziz (@mamasodikoff)

🥛 Ayron olib bering: tirikchilik.uz/cosmos

- Web sayt: flutterdev.uz
Download Telegram
Notes:
// ================== SOLID Principles ==================

// 1. Single Responsibility Principle (SRP)
// A class should have only one reason to change.

class SaveUserManager {
void saveUser() {
print("User saved.");
}
}

class ValidateUserManager {
void validateUser() {
print("User validated.");
}
}

// ======================================================

// 2. Open-Closed Principle (OCP)
// Software entities should be open for extension but closed for modification.

abstract class SalaryManager {
int salary();

int? bonus() {
return 200; // default bonus
}
}

class Junior extends SalaryManager {
@override
int salary() => 400;
}

class Middle extends SalaryManager {
@override
int salary() => 900;
}

class Senior extends SalaryManager {
@override
int salary() => 1400;

@override
int? bonus() => 400;
}

// ======================================================

// 3. Liskov Substitution Principle (LSP)
// Subtypes must be substitutable for their base types.

abstract class Shape {
int area();
}

class Rectangle extends Shape {
int height;
int width;

Rectangle(this.height, this.width);

@override
int area() => height * width;
}

class Square extends Shape {
int side;

Square(this.side);

@override
int area() => side * side;
}

// ======================================================

// 4. Interface Segregation Principle (ISP)
// No client should be forced to depend on methods it does not use.

abstract class DrivingTransport {
void drive();
}

abstract class FlyingTransport {
void fly();
}

abstract class SwimmingTransport {
void swim();
}

class BMW implements DrivingTransport {
@override
void drive() {
print("BMW driving on road...");
}
}

class Boat implements SwimmingTransport {
@override
void swim() {
print("Boat swimming on water...");
}
}

class Airplane implements FlyingTransport {
@override
void fly() {
print("Airplane flying in the sky...");
}
}

// ======================================================

// 5. Dependency Inversion Principle (DIP)
// High-level modules should not depend on low-level modules.
// Both should depend on abstractions.

abstract class AuthService {
void signIn();
}

class SmsAuth extends AuthService {
@override
void signIn() {
print("Signed in with SMS");
}
}

class GoogleAuth extends AuthService {
@override
void signIn() {
print("Signed in with Google");
}
}

class UserAuth {
final AuthService authService;

UserAuth(this.authService);

void signIn() {
authService.signIn();
}
}

// ======================================================

void main() {
// SRP
SaveUserManager().saveUser();
ValidateUserManager().validateUser();

// OCP
SalaryManager junior = Junior();
print("Junior salary: ${junior.salary()}, bonus: ${junior.bonus()}");

SalaryManager senior = Senior();
print("Senior salary: ${senior.salary()}, bonus: ${senior.bonus()}");

// LSP
Shape rect = Rectangle(10, 20);
Shape square = Square(15);
print("Rectangle area: ${rect.area()}");
print("Square area: ${square.area()}");

// ISP
BMW().drive();
Boat().swim();
Airplane().fly();

// DIP
UserAuth userAuth1 = UserAuth(GoogleAuth());
userAuth1.signIn();

UserAuth userAuth2 = UserAuth(SmsAuth());
userAuth2.signIn();
}


More: https://dev.to/harsh8088/mastering-solid-principles-in-flutter-3hp7

@flutterdevuz
1👍1
⚡️ 5 Modern Dev Tips You Should Be Using in 2025

1️⃣ AI is your coding buddy, not your replacement – Use tools like ChatGPT or Copilot to brainstorm, debug, or refactor. But keep your brain in the loop. AI speeds you up, you keep the quality.

2️⃣ Automate the boring stuff – Scripts, GitHub Actions, CI/CD… let the machines handle what you repeat daily. Free your time for the fun, creative part of coding.

3️⃣ Dark mode ≠ productivity – Real productivity comes from using extensions & plugins that actually save time. Example: GitLens for Git history or Flutter DevTools for performance.

4️⃣ Learn to read docs faster – Instead of copy-pasting StackOverflow answers, go straight to the official docs. It feels slower at first but saves you months of future headaches.

5️⃣ Build your digital second brain – Use Notion/Obsidian/whatever you like to save snippets, AI prompts, and fixes you discover. Future-you won’t need to “Google that same error for the 50th time.”

@flutterdevuz
🔥2🆒1
Har bir Flutter dasturchisi bilishi kerak boʻlgan komandalar!

#commands

@flutterdevuz
1👍1
Flutter dastur qotyabdimi?

Muammo “framework”da emas, “performance”ni boshqarishda bo‘lishi mumkin.

• UI oqimini band qilmang:
build() yoki setState() ichida og‘ir hisob-kitoblar qilmay, isolate’ga chiqarib qo'ying.

• Og‘ir grafiklardan ehtiyot bo‘ling:
ShaderMask, BackdropFilter kabi effektlar chiroyli, lekin CPU/GPU’ni yutvoradi. Minimal ishlating.

• Rasmlarni optimallashtiring:
Katta va "compress" qilinmagan rasmlar xotira va tezlikni tushiradi. cacheWidth/cacheHeight bilan moslashtiring.

- Qayerda muammo borligini qanday bilasiz?
- Flutter DevTools → Performance → Timeline

1. "flutter run --profile" rejimida ishga tushiring.
2. "DevTools" ochib, Performance ga o‘ting.

Qizil ustun → frame sarfi (16.7ms / 60Hz) buzilganini bildiradi.

UI vs Raster → kod yoki render qayerda sekinligini ko‘rasiz

Shader spike → shaderlar kompilyatsiyasi vaqtida lag bo‘lgan

Rebuild/Repaint → keraksiz qayta chizishlarni kamaytiring (const, RepaintBoundary)

GC spike → xotira bosimi kuchli bo‘lsa chiqadi
1👍1
Barmoq izi skaneri paketimni stabil (v1.0.0) versiyasi chiqdi!

Loyihalaringizda ishlatib ko'ring:

https://pub.dev/packages/zkfinger10

@flutterdevuz
🔥62
🎯 Google Play’ning 16KB sahifa o‘lchami talabi muddati yaqinlashmoqda — va ha, sizning Flutter ilovangiz ham bu tekshiruvdan o‘tishi kerak.

Yaqinda men APK faylimni sahifa o‘lchami mosligini tekshiruvchi oddiy shell skript orqali sinovdan o‘tkazdim — yaxshi tomoni shundaki, ilovam muvaffaqiyatli o‘tdi

🙌 Ushbu foydali tekshirish skriptini baham ko‘rgan NITIN PRAKASH’ga katta rahmat.

🎯 Flutter ilovangiz 16KB sahifa o‘lchamiga mos kelishini tekshirish bosqichlari:

1️⃣ Root katalogda check_elf_alignment.sh nomli fayl yarating va skriptni joylang.
2️⃣ Skriptni "runnable" qiling: chmod +x check_elf_alignment.sh
3️⃣ Buyruqni bajaring: flutter build apk --release
4️⃣ So‘ng Flutter loyihangizdagi build apk fayl manzili bilan skriptni ishga tushiring:
./check_elf_alignment.sh app/build/outputs/apk/release/app-release.apk

Skript sizning native kutubxonangiz zamonaviy Android qurilmalari uchun 16KB sahifa o‘lchami talablari bilan mosligini tekshiradi.

🔗 Skript havolasi: https://gist.github.com/Mamasodikov/5225307756126504c1dce1153d24958d

🗓 Shuningdek, bu talabning oxirgi muddati — 2025-yil 1-noyabr. Agar native kutubxonalarni qayta kompilyatsiya qilish yoki dependency’larni yangilash biroz vaqt olsa, 2026-yil 31-maygacha muddatni cho'zishni so‘rashingiz mumkin.

@flutterdevuz
🎉1🆒1
Dasturchilar, studentlar, miyamizni qidiramiz... Qayerdadir shetta, his qilyabsizmi?
😁2
Срочно! Macbook M3 Pro 14'' 18/512

🍏 Macbook M3 Pro 14'' #m3pro #mac
📟 RAM: 18GB
💾 SDD: 512 GB
💻 Rangi: Space Black
💵 $1359

Xolati ideal, garantiyasi tugaganiga hali 1 oy bo'lmadi. Ko'p ishlatilmagan.
Faqat chexolda ishlatilgan. Ekranida steklo zashitnik bor.

🔋Batareya: 75 sikl | 100 %

Karobka dokument, komplektda hamma narsasi bor.

(Obmen va bo'lib to'lash yo'q)

Kontakt: @successisnotfinal
🔥21👍1
Ibrohimbek Davronov:

Har bir mobile dasturchi push notification bilan ishlashga to'g'ri keladi... 🤔

Lekin ko'p hollarda:
Dokumentatsiya tarqoq
Setup jarayoni chalkash
Platform-specific issues ko'p

Shu sababli do'stim Hayotbek 🇵🇸 bilan birgalikda Flutter uchun to'liq, step-by-step qo'llanma yaratdik! 📚

Qamrab olingan mavzular:
🔹 Firebase Cloud Messaging integratsiyasi
🔹 Android va iOS uchun alohida sozlamalar
🔹 Token management
🔹 Notification handlers (background/foreground/terminated)
🔹 Postman collection bilan testing
🔹 Real-world kod namunalari

Maqsad oddiy: yangi boshlovchilar uchun ham, tajribali dasturchilar uchun ham foydali reference yaratish.

🔔 Notification haqida keyingi postlarni kuting!

Fikrlaringizni izohlarda qoldiring 💬

Documentation Link: https://lnkd.in/dF4WXduk

Manba: https://www.linkedin.com/posts/ibrohimbek-davronbekov_flutterdevelopment-firebase-pushnotifications-activity-7387828098001612800-mhto

@flutterdevuz
👍4🔥4