我正在尝试以日期格式添加SuperScript。
就像从服务器“ 9/5/2019”和“ 2019年5月9日获得价值”一样 我必须将其转换为“ 2019年5月9日”, 应该是SuperScript。
exp
const Newdate =“ 2019年5月9日”
const NewDateDormat =“ 2019年5月9日”
两个日期我都必须同时显示(Newdate和NewDateDormat) 此格式为“ 2019年5月9日”。此处应为“ SuperScript”。
答案 0 :(得分:0)
将其插入DOM时,只需将“ th”放在“ sup”标记之间。