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

router.stateService.go History Push Error #28

Closed
wallzero opened this issue Feb 24, 2017 · 4 comments
Closed

router.stateService.go History Push Error #28

wallzero opened this issue Feb 24, 2017 · 4 comments

Comments

@wallzero
Copy link
Contributor

wallzero commented Feb 24, 2017

After upgrading from 0.3.0 to 0.4.0, I am getting the following error message when using router.stateService.go(statename):

Failed to execute 'pushState' on 'History': A history state object with URL 'http://sales/' cannot be created in a document with origin 'http://localhost:8090' and URL 'http://localhost:8090/home'.

I still transition correctly to the state; but the url doesn't reflect. Navigating manually with the address also works.

@elboman
Copy link
Member

elboman commented Feb 25, 2017

I cannot recreate it, would you mind creating a plunker so I can take a deeper look?

Also, what browser are you using?

@wallzero
Copy link
Contributor Author

I was using Chrome 53+ I believe. I was also bootstrapping the router config.

I am working on a rewritten prototype to demonstrate what I need for issue 26. I'll share once complete and it should be able to test both issues.

@wallzero
Copy link
Contributor Author

wallzero commented Mar 1, 2017

So now I have another issue I've found since I promoting to a non-root URL. Using 'ui-router-react-digest' in <base>, ui-router is getting caught in an infinite redirecting loop. You can see it's also leaving a preceeding / after it errors out: https://wallzero.gitlab.io/ui-router-react-digest/

Anyhow, if you clone the project from here and run via 'npm run build:demo && npm run start:demo:dev' you'll see the error:

Failed to execute 'pushState' on 'History': A history state object with URL 'http://tab2/' cannot be created in a document with origin 'http://localhost:8080' and URL 'http://localhost:8080/tab1'.

You'll have to manually go to localhost:8080/tab1 to actually see the views render.

It's still very much a work in progress so be gentle if I did anything stupid. :-)

@wallzero
Copy link
Contributor Author

wallzero commented Mar 4, 2017

I'm going to close this issue and open a new ticket in ui-router/core, since it's unlikely an issue with ui-router/react.

@wallzero wallzero closed this as completed Mar 4, 2017
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