Skip to content

Conversation

@geoidesic
Copy link

When a user of an SPA hits page refresh or uses a bookmark as an entry
point into the app, it is necessary to call the EWD.setCookie function
in order to re-register the session and to map the session cookie to
the new web socket.

If the href has a different path to that when the token was first
generated, you can end up in a situation where QEWD loses track of the
session because it is seen as a new token.

This modification allows one to prevent this undesirable behaviour by
providing the ability to specify the cookie’s path and providing a
sensible default for an SPA

geoidesic and others added 5 commits March 14, 2018 00:33
This event is raised by socket.io in the event of the websocket-server not being available and throwing an ERR_CONNECTION_REFUSED error. This is distinct and different from the `disconnect` event which ewd-client already caters for.
When a user of an SPA hits page refresh or uses a bookmark as an entry
point into the app, it is necessary to call the EWD.setCookie function
in order to re-register the session and to map the session cookie to
the new web socket.

If the href has a different path to that when the token was first
generated, you can end up in a situation where QEWD loses track of the
session because it is seen as a new token.

This modification allows one to prevent this undesirable behaviour by
providing the ability to specify the cookie’s path and providing a
sensible default for an SPA
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

Successfully merging this pull request may close these issues.

1 participant