【发布时间】:2023-03-05 14:21:01
【问题描述】:
util.isNullOrUndefined(object) 已被贬值,我找不到任何替代品。有人可以指出一个可行的替代方案吗?
if (isNullOrUndefined(this.activeAppKey) || this.activeAppKey.trim().length === 0) {
this.activeAppKey = sessionStorage.getItem(AppConstants.APP_KEY);
}
【问题讨论】:
-
if (!this.activeAppKey || this.activeAppKey.trim().length === 0) { this.activeAppKey = sessionStorage.getItem(AppConstants.APP_KEY); }