Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

412 B
Raw Blame
import { Injectable } from '@angular/core';
import { Query } from '@datorama/akita';
import { CurrentUserState, CurrentUserStore } from './current-user.store';

@Injectable()
export class CurrentUserQuery extends Query<CurrentUserState> {
  constructor(protected store:CurrentUserStore) {
    super(store);
  }

  isLoggedIn$ = this.select((state) => !!state.loggedIn);

  user$ = this.select((user) => user);
}