I got this as JSON data from the API and need to calculate the age:(我是从API获得的JSON数据,需要计算年龄:)
{"fullname":"Nikita","email":"[email protected]","city":"London","mobile":"08888888888","birthday"{"year":1980,"month":7,"day":23}}
Currently, I'm showing the date of birth as {{anon.birthday}}
which results in 1980-7-23
.(目前,我将出生日期显示为{{anon.birthday}}
,结果为1980-7-23
。) I would like to show the age instead.(我想显示年龄。) How can I go about doing this?(我该怎么做呢?)
ask by Nikita Gupta translate from so
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…