Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Period-separated recursive model creation #854

Closed
jamesplease opened this issue Jan 13, 2014 · 2 comments
Closed

Period-separated recursive model creation #854

jamesplease opened this issue Jan 13, 2014 · 2 comments

Comments

@jamesplease
Copy link
Member

I've been thinking about the current implementation of modules in Marionette and one thing about them strikes me as strange. To explain, let me start by examining a list of their properties:

  1. They can soon be extended. This makes them similar to most of the objects in the Backbone-Marionette universe, such as Item Views
  2. They have a start/stop state, and a series of initializers and finalizers associated with them. This makes them like Applications.
  3. They can recursively be nested by calling Application.module and passing a period-separated string of names. This makes them...a bit odd?

The third item there really stands out to me. Maybe there's some good use-case for the recursive parent-child creation mechanism, but I can't think of any. Do you use it? If there are some good uses, then, well, that's fine. I wouldn't be surprised if I'm simply not creative enough to see the use.

But if not I would propose removing it entirely in the next big update to Marionette, for the sake of a more consistent, simpler framework.

@cobbweb
Copy link
Member

cobbweb commented Jan 13, 2014

Yes, I use it extensively... our directory structure is mapped to the namespaces. So files in js/editor/sidebar/*.js are all in the Editor.Sidebar namespace.

@jamesplease
Copy link
Member Author

Ah, okay. Well, then I guess this issue is as good as closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants