Apollo 2.0 allows user to manage the application global state via apollo-link-state by using the browser's cache. I know it is a common pattern in Redux to have a variable isAuthenticated
in the global store to restrict access (and to my understanding this is not saved in the cache).
My question is: is it dangerous to have a state isAuthenticated
saved in the cache using apollo-link-state? Can the user not simply modify the state of isAuthenticated
and be granted access to the site? Should I therefore avoid using isAuthenticated
as a global variable in Apollo Client?