Store: router-plugin bug v3.5.0 when use baseHref

Created on 23 Jul 2019  路  10Comments  路  Source: ngxs/store

I'm submitting a...


[ x ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report  
[ ] Performance issue
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request => https://github.com/ngxs/store/blob/master/CONTRIBUTING.md
[ ] Other... Please describe:

Current behavior


baseHref in url will be copy once when you refresh browser.

Expected behavior

Minimal reproduction of the problem with instructions

Environment


Libs:
- @angular/core version: X.Y.Z
- @ngxs/store version: X.Y.Z


Browser:
- [ x ] Chrome (desktop) version 75.0.3770.142
- [ ] Chrome (Android) version XX
- [ ] Chrome (iOS) version XX
- [ ] Firefox version XX
- [ ] Safari (desktop) version XX
- [ ] Safari (iOS) version XX
- [ ] IE version XX
- [ ] Edge version XX

For Tooling issues:
- Node version: v10.16.0 
- Platform:  Mac 

Others:

plugins

Most helpful comment

Released in v3.5.1! Please test.

All 10 comments

@arturovt Could this be related to PR #1159 and the fix for issue #1153?

Please could you provide a repo or stackblitz demonstrating the issue?

@maartentibau
I can't provide repo demonstrating my issue now.

https://github.com/Jimmysh/angular-stackblitz/tree/ngxs
this repo can demo NgxsRouterPlugin V3.5.0 not support baseHref. but 3.4.3 is good.

@Jimmysh that's better :)

I just ran into the same issue when setting APP_BASE_HREF dynamically during SSR.

The router recognizes the initial route correctly (with stripped baseHref), this triggers the router plugin, which then in turn performs an additional navigation:
image

to the non-baseHref-stripped URL, because currentSerializedUrl != currentUrl. The linked PR #1178 should be working, since normalize strips the baseHref:
image

@Dav1dde Thanks for investigation and additional help, I appreciate that :tada:

Sorry if I ask, but that is a major obstacle for using the library in an actual project. I am now using the @dev version, but I think that lots of people will fill far more confortable being able to depend on a real realse (3.5.1 ???). When such release is planned to rollout?

@markwhitfeld ping

Could we get patch release for this? or should i downgrade the dependency?

Released in v3.5.1! Please test.

Was this page helpful?
0 / 5 - 0 ratings