-
-
Notifications
You must be signed in to change notification settings - Fork 40
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
Accept HTML only custom element in moduleId RouteConfig #49
Comments
Closing this as a duplicate. We have a feature tracked to enable "view only" routes. Thanks! |
@EisenbergEffect any link? |
I don't find any feature like this. Yes is there #25, but is about layout view-only no page view-only. Take app-contacts app and put this code on app.js: config.map([
{ route: ['', '/'], **moduleId: 'no-selection.html',** title: 'Select'},
{ route: 'contacts/:id', moduleId: 'contact-detail', name:'contacts'}
]); The aurelia-template-route don't work with moduleId path. But if I make little change on I want know if a way to do this, without change source code? |
I also ran into this limitation. As far I as I can tell, we are required to create an empty view-model to back the view. @EisenbergEffect, can you give us a link to whatever issue is tracking this feature request? The issue @AbraaoAlves referenced, #25, does not appear to be related. |
I thought we had a feature for this somewhere. Perhaps, I was wrong? I'll re-open this. |
@EisenbergEffect k, thanks. When I attempted to get this to work within the current architecture, I used the
However, this results in the error message
This Unfortunately, I keep expecting custom elements and views to behave in a similar fashion, but that expectation is consistently wrong. |
That's it @carusology, clear like water. |
@EisenbergEffect, @AbraaoAlves I think this can be closed since #50 was merged. |
I'm submitting a feature request
Expected/desired behavior:
The moduleId should work not just ViewModels, but also HTML only custom elements.
Like tag
<require from="my-component.html">
, that accept viewModels and Views, moduleId in RouteConfig should accept string like this:What is the motivation / use case for changing the behavior?
Less is MORE. Write empty class to just route works, should not be the Aurelia way.
The text was updated successfully, but these errors were encountered: