You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are trying to set the UI Params to include both state params and a hash. An example would be
/shop?page=1#fruit=orange
Problem
The _set function within the Ng2LocationServices is not properly parsing the hash before sending it along to the Angular Path Location Strategy.
The function assumes the hash can be prepended to the URL always which is not the case when we combine state params with a hash. The incorrect output from this would be
/shop#fruit=orange?page=1
Suggested Fix
I'm not entirely sure why the code currently assumes the hash should always be prepended to the path, but may this be a potential solution.
The main suggestion here is if we have search params, append the hash to the search not the path. If there are no search params, then do what exist currently and append the hash to the path.
The text was updated successfully, but these errors were encountered:
Use Case
We are trying to set the UI Params to include both state params and a hash. An example would be
Problem
The _set function within the
Ng2LocationServices
is not properly parsing the hash before sending it along to the Angular Path Location Strategy.The function assumes the hash can be prepended to the URL always which is not the case when we combine state params with a hash. The incorrect output from this would be
Suggested Fix
I'm not entirely sure why the code currently assumes the hash should always be prepended to the path, but may this be a potential solution.
The main suggestion here is if we have search params, append the hash to the search not the path. If there are no search params, then do what exist currently and append the hash to the path.
The text was updated successfully, but these errors were encountered: