When the ngOnInit() function is called, I extract query parameters using the code snippet below. How can I convert the observable to a string?
constructor(private router: ActivatedRoute) { }
textToDisplay: Observable<string>;
ngOnInit() {
this.textToDisplay = this.router
.queryParamMap
.pipe(map(params => params.get('session_id') || 'None'));
}