【发布时间】:2022-01-19 22:59:57
【问题描述】:
我有这个对象
{
'http://schemas.xmlsoap.org/ws/2005/05/identity/claims/nameidentifier': '918312asdasc812',
'http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name': 'Login1',
'http://schemas.microsoft.com/ws/2008/06/identity/claims/role': 'User'
}
如何读取键“http://schemas.xmlsoap.org/ws/2005/05/identity/claims/nameidentifier”的值?
解决方案:
obj['http://schemas.xmlsoap.org/ws/2005/05/identity/claims/nameidentifier']
【问题讨论】:
-
你试过
obj['http://schemas.xmlsoap.org/ws/2005/05/identity/claims/nameidentifier']吗? -
@Andy 谢谢它的工作原理!
标签: javascript json typescript