MVC (Model-View-Controller) એક આર્કિટેક્ચરલ પેટર્ન છે જે એપ્લિકેશનને ત્રણ ભાગોમાં વિભાજિત કરે છે — Model (ડેટા/લોજિક), View (UI/પ્રસ્તુતિ), અને Controller (ઇનપુટ હેન્ડલ કરે છે, સંકલન કરે છે) — ચિંતાઓના વિભાજનને પ્રોત્સાહિત કરે છે. તે મૂળભૂત છે, ઘણી ભિન્નતાઓ (MVP, MVVM) સાથે.।
ત્રણ ઘટકો
MODEL → data and business LOGIC (the core: data, rules, state) — independent of the UI
VIEW → the UI/PRESENTATION (displays data to the user) — what the user sees
CONTROLLER → handles user INPUT, coordinates between Model and View (processes requests,
updates the model, selects the view)
→ SEPARATION: data/logic (Model) ≠ presentation (View) ≠ input handling (Controller)
