Skip to content

Instantly share code, notes, and snippets.

🎯
Focusing

Fitch DrFitch

🎯
Focusing
Block or report user

Report or block DrFitch

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@DrFitch
DrFitch / auth.guard.ts
Created Feb 18, 2018 — forked from codediodeio/auth.guard.ts
Angular Firebase Router Guard with Browser Refresh
View auth.guard.ts
import { Injectable } from '@angular/core';
import { CanActivate, ActivatedRouteSnapshot, RouterStateSnapshot, Router } from '@angular/router';
import { Observable } from 'rxjs/Observable';
import { AngularFireAuth } from 'angularfire2/auth';
import 'rxjs/add/operator/do';
import 'rxjs/add/operator/map';
import 'rxjs/add/operator/take';
@Injectable()
export class AuthGuard implements CanActivate {
You can’t perform that action at this time.