Skip to content

Instantly share code, notes, and snippets.

@BrightnBubbly
Created May 4, 2020 04:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save BrightnBubbly/c786463ee02936f3368a80d269eb7868 to your computer and use it in GitHub Desktop.
Save BrightnBubbly/c786463ee02936f3368a80d269eb7868 to your computer and use it in GitHub Desktop.
import { Injectable } from '@angular/core';
export declare interface User {
token: string;
apiKey: string;
username: string;
}
@Injectable({
providedIn: 'root',
})
export class StateService {
constructor() {}
private _user: User;
get user(): User {
return this._user;
}
set user(user: User) {
this._user = user;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment