如何将 LocalStorage 与MSAL.js一起使用?
根据这个,有一个属性,cacheLocation,我需要设置为'localStorage'。
以下仍在使用 sessionStorage:
var clientApplication = new Msal.UserAgentApplication(applicationConfig.clientID, applicationConfig.authority, function (errorDesc, token, error, tokenType) {
// Called after loginRedirect or acquireTokenPopup
});
clientApplication.cacheLocation = 'localStorage';