In a finished Backbone app, you don't have to write the glue code that looks into the DOM to find an element with a specific id, and update the HTML manually — when the model changes, the views simply update themselves.
This makes the goal of our Turn Based Game much clearer and makes it silly how simple the resulting code should be.
Models should be generally unaware of views. Instead, views listen to the model "change" events, and react or re-render themselves appropriately.
This makes so much sense and now that we have a framework that supports it it makes more sense why you wanted our games to be structured the same way.
Not sure what this REST/RESTful API stuff means? The example data looks similar to the APIs we've used in class.
Routing sounds very interesting.
Collections are derived from Arrays, while Models are derived from Objects
That seems important.
Under the hood, using view.$('...') is synonymous with calling view.$el.find('...'). These localized queries greatly cut down on superfluous DOM operations.
Takeaways:
This makes the goal of our Turn Based Game much clearer and makes it silly how simple the resulting code should be.
This makes so much sense and now that we have a framework that supports it it makes more sense why you wanted our games to be structured the same way.
Not sure what this REST/RESTful API stuff means? The example data looks similar to the APIs we've used in class.
Routing sounds very interesting.
That seems important.
That does too.