Mac
01/07/2022, 8:04 PMredirectTohttp://localhost:3000/foobarhttp://localhost:3000/foobar#access_token=123abc&expires_in=3600&you_get=the_ideaMac
01/07/2022, 8:06 PMredirectTosignInMac
01/07/2022, 8:08 PM3.2.164.0.111.29.1Mac
01/07/2022, 8:13 PMts
const redirectPath = route.query.redirect as string;
const redirectTo = `${window.location.origin}${redirectPath || '/'}`;
const { error } = await supabase.auth.signIn({ provider }, { redirectTo });Mac
01/07/2022, 8:16 PMafterEachts
import { NavigationFailure, RouteLocationNormalized } from 'vue-router';
export function clearHashGuard(
  from: RouteLocationNormalized,
  to: RouteLocationNormalized,
  failure: void | NavigationFailure | undefined
) {
  // Hash gets cleared properly on Home view
  // And I need to preserve query params on SignIn
  if (!['Home', 'SignIn'].includes(from.name as string)) {
    history.pushState(
      {},
      document.title,
      window.location.pathname + window.location.search
    );
  }
}Mac
01/07/2022, 8:24 PM