Skip to content
GitHub

Micro-Frontend ရဲ့ အားသာချက်များ

Micro-Frontend ကို သုံးခြင်းရဲ့ အဓိက အကျိုးကျေးဇူးကတော့ “လွတ်လပ်ခြင်း (Independence)” ပါပဲ။

၁။ Independent Deployment (သီးခြား Deploy လုပ်နိုင်ခြင်း)

Section titled “၁။ Independent Deployment (သီးခြား Deploy လုပ်နိုင်ခြင်း)”

ဒါက အရေးအကြီးဆုံး အချက်ပါ။

  • Checkout Team က သူတို့ Feature ပြီးတာနဲ့ တန်းပြီး Deploy လုပ်လို့ရတယ်။
  • Profile Team မပြီးသေးလို့ စောင့်နေစရာ မလိုဘူး။ Release Cycle တွေ မြန်ဆန်လာပါတယ်။

၂။ Technology Agnostic (ကြိုက်ရာ နည်းပညာ သုံးနိုင်ခြင်း)

Section titled “၂။ Technology Agnostic (ကြိုက်ရာ နည်းပညာ သုံးနိုင်ခြင်း)”
  • Team A က React ကျွမ်းကျင်ရင် React သုံး။
  • Team B က Vue ကျွမ်းကျင်ရင် Vue သုံး။
  • Team C က Angular ကျွမ်းကျင်ရင် Angular သုံး။ နောက်ဆုံးမှာ အားလုံး ပေါင်းစည်းသွားမှာပါ။ (ဒါပေမယ့် Performance အရ Framework တွေ အများကြီး ရောသုံးတာကို သတိထားသင့်ပါတယ်)

၃။ Isolated Faults (ပြဿနာ သီးခြားဖြစ်ခြင်း)

Section titled “၃။ Isolated Faults (ပြဿနာ သီးခြားဖြစ်ခြင်း)”

Checkout Micro-Frontend မှာ Error တက်ပြီး ပျက်သွားရင်တောင်၊ Product List က ဆက်လုပ်နေမှာပါ။ App တစ်ခုလုံး “ဖြူ” သွားတာ (White Screen of Death) မျိုး မဖြစ်တော့ပါဘူး။

စိန်ခေါ်မှုများ (Challenges)

Section titled “စိန်ခေါ်မှုများ (Challenges)”

Micro-Frontend က ကောင်းပေမယ့် အလကား မရပါဘူး။

  1. Complexity: Setup လုပ်ရတာ အရမ်း ရှုပ်ထွေးပါတယ်။ (Webpack Module Federation, Single-SPA စတာတွေ သိဖို့ လိုပါတယ်)
  2. Performance: Framework တွေ ထပ်နေရင် (React 2 ခါ Load လုပ်မိတာမျိုး) Site က လေးသွားနိုင်ပါတယ်။
  3. Consistency: Team တွေ မတူတော့ Button ဒီဇိုင်းတွေ၊ Font တွေ မတူတာမျိုး ဖြစ်တတ်ပါတယ်။ (Design System ကောင်းကောင်း လိုပါတယ်)