Jump to content
Sign in to follow this  
Makwana Prahlad

view vs view-model

Recommended Posts

I think you're referring to MVC Model View Controller.  

If you're asking about the diff between Model and View,

The Model gets the data from your tables, or other data source, and the View displays it on the browser page.

I use my MVC everyday.

Keeps me sane.

 

Edited by niche

Share this post


Link to post
Share on other sites

The idea of a view-model is a slight alteration to the ordinary Model-View-Controller paradigm. First of all, to make things clear, there's no solid definition for what MVC is, it's just the idea of dedicating one of three different functions to each piece of your software.

In the paradigms that contain a view-model component (I've seen the Model-View-ViewModel paradigm mentioned before), a view-model is a model that is attached to a view in such a way that an alteration to the model directly alters the view that it is connected to without the need for a controller to read the model and pass the data to the view.

Share this post


Link to post
Share on other sites

Good to know there're hybrids.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...