If you create an import at the top of your tsx/ts file to getAppStore eg
import { getAppStore } from 'jimu-core';
The you can make a call to get the state of the application, with
let state = getAppStore().getState();
The state object has the details of the logged in user. eg