Input required

In previous chapters, we've gone into detail about the API we're going to be communicating with. There's no denying that it's one of the key parts of any application design; in fact many projects can live or die based on the quality of the API they're integrating with, but we've discussed this in the past two chapters and we've still got a lot to cover. From here on, we're generally going to assume that we're working with a well-designed RESTful API that works well with Ext JS. This'll give us some room to concentrate on some new ideas.

Tip

That's not to say you can skip over the API when designing your application. It is very rare you'll be working with a perfect backend, so keep analyzing whether the server is providing the endpoints you need.

We'll move on to looking at the rest of the application, but in a different way to previous chapters; once the data's been pulled down from the server, we'll try and consider how it's going to move through our app. We'll also look at two other facets of the design in more detail: routing and events. Why this change in direction compared to previous chapters?

As our applications become more complicated, we have to continually think about how to keep that complexity under control. These three features: view models, events, and routing, all allow a "fire and forget" attitude, wire up some basic configuration, trigger an action at the source, and this bit of code is done. Somewhere else in the application will subscribe to this action—be it a view model binding, a routing change or the firing of an event—and consume it accordingly.

We'll first identify our views and controllers as we have in the past and look at how this will inform the routing, view models and events that will power the functionality of our application.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset