14 Apr 2011 12:28 PM #1
[CLOSED][b3] MVC structure suggestion
would be to pluralize the directories under 'app' in keeping with most other mvc frameworks available.
also, it would seem that we are going down the convention over configuration path with Ext that we've seen in Rails, et al. It would be logical to assume that the great majority of Ext apps will have more than 1 class in each of these directories so assuming the directory name represents the contents, it would make sense to pluralize the directories (model -> models, view -> views, controller -> controllers)
14 Apr 2011 4:15 PM #2
We chose the singular approach because it matches our class naming conventions. Each of those directories maps to a package namespace, e.g.:
MyApp.model.User vs MyApp.models.User
MyApp.view.user.Edit vs MyApp.views.users.Edit
We never pluralize package names in the framework and want application code and framework code to feel as alike as possible. By keeping to these naming conventions we can leverage our strong class model and tooling to make applications easier to write and deploy.
14 Apr 2011 4:28 PM #3
Ed can you speak a little about what happened to the routing functionality in prior revisions of MVC?
14 Apr 2011 4:31 PM #4
The great thing about what we have in 4.0 though is that it's only 3 classes, yet delivers an enormous amount of power. I love writing apps with this stuff
14 Apr 2011 4:52 PM #5
Simplicity is great but I would rather have to worry about 5 classes and have the routing and history management. The routing functionality becomes very important with larger applications (especially direct navigation to secondary screens to accelerate development). I had experimented a bit with the functionality you had and it seemed promising but I am sure there are complexities I have not considered.
By mschwartz in forum Ext:BugsReplies: 8Last Post: 22 Feb 2011, 2:05 PM
By ibnesayeed in forum Ext:BugsReplies: 0Last Post: 17 Feb 2011, 12:13 AM
By magon in forum Ext GWT: DiscussionReplies: 1Last Post: 7 Jul 2009, 5:27 AM
By mschwartz in forum Ext 3.x: BugsReplies: 1Last Post: 4 Jun 2009, 8:19 AM
By willydee in forum Ext 2.x: BugsReplies: 2Last Post: 3 Nov 2007, 6:25 AM