I have an application that uses Stripe Checkout. When the user clicks on the "buy" button on the "product" page, a value is stored in VueX which indicates which product was selected, then a request is sent to the backend that redirects to stripe checkout. Upon completion, the user is redirected to the "Success" page. In the "Success" page, I need to access the value of that variable from the VueX store, but since the page was redirected to another domain, my application loses its state that was set on the "product" page.
Initially, I tried to do this without vueX and only used local storage, which didn't work either, since the data was lost after the redirect since the subdomain changed after the redirect, but it seems that the same thing is happening with VueX as well.
The only solution I could think of was to save the entire vueX store to localStorage but I am unsure if this will work. How can I make this variable persist even after a redirect to a different domain and then to a new sub-domain?