Angular 2, Observables - return some data from subscribe
<p>I have a login component and a simple method:</p>

<pre><code>login(event) {       
    event.preventDefault();
    this.authService.login(this.user);       
}
</code></pre>

<p>This is my <code>AuthService</code>:</p>

<pre><code>export class AuthService {
    constructor(private jsonApiService:JsonApiService) {
    }

    isLoggedIn: boolean = false;

    login(user:User): any {
        this.jsonApiService.post('/token', user)
            .subscribe(
                resp =&gt; {
                   check if success,
                   store token to localstorage,
                   set isLoggedIn = true
                   * return new object with data about success/error


                },
                err =&gt; {    
                    handle error
                    * return new object with data about success/error
                });
    }

    logout(): void {
        this.isLoggedIn = false;
    }
}
</code></pre>

<p>This code works fine. I get response, but I am wondering how to return some data from service to component. I don't want to move subscribe to component, because, I believe, handling must be in the AuthService.</p>