📌  相关文章
📜  'string | 类型的参数null' 不能分配给“字符串”类型的参数.类型 'null' 不可分配给类型 'string' - TypeScript 代码示例

📅  最后修改于: 2022-03-11 14:48:29.061000             🧑  作者: Mango

代码示例1
this.currentUser = JSON.parse(localStorage.getItem('currentUser') || '{}');