-
Notifications
You must be signed in to change notification settings - Fork 3k
Typed parameters don't seem to get used, and states using typed parameters don't load properly #1048
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
Comments
Another observation is that routing does not seem to work properly with typed parameters based on the above plunker. click the "do it" link to navigate to the "test" state, and then right click and go back (the back event needs triggering in the app iframe, not the plunker site itself). This works fine, and takes you back to the "home" state. Now right click and go forwards. The URL changes, but the state does not. This does not seem to happen when typed parameters are not used. |
Yup, I'm investigating this. It's going to require queuing some configuration until runtime, so it might take a bit. Thanks for the report. |
Was also trying to experiment with the typed params. FWIW here's the above plunk, showing a custom type in the state def kinda working: http://plnkr.co/edit/A185Dg A bit strange seems that the default types get registered only when usercode injects |
I did some debugging and I think this is due to the delay caused by the type queue. The types are flushed (i.e. registered?) asynchronously, when I tried injecting it into an Is there any other place this injection should be done so that it flushes the queue before the routing processing starts? |
Setting |
So, is there any news on getting typed parameters to work? This feature is exactly what I need right now, but I haven't been able to figure out how to get it to work correctly. Is there a branch that has it working? Is somebody still working on the fix? |
+1 |
Fixed in 0.2.12. More Type/param fixes coming in 0.2.13, which is imminent. |
Hello,
I just built the latest version to have a play with typed parameters, which sound extremely useful!
Even using one of the pre-supplied types such as "bool", or creating my own full of console.log's, I don't see anything to indicate that the type is actually being used.
The plunker below illustrates this issue; clicking the button should set the url to #/test/0 as per how the built in "bool" type seems to work, but does not. I have also tried to create my own custom type, but it seems to have no effect.
http://plnkr.co/edit/wDB7CZb9iTdl9h7iP9lB
Am I being silly and doing something wrong or has a recent commit broke something?
Thanks in advance,
keep up the awesome work!
The text was updated successfully, but these errors were encountered: