我JSON.stringify()在 html 上使用<input>通过 websocket 发送,如下所示:
JSON.stringify({
numberValue: $('#numberValue').val()
})
但它编码$('#numberValue').val()为String.
如何将其编码为Number?
我JSON.stringify()在 html 上使用<input>通过 websocket 发送,如下所示:
JSON.stringify({
numberValue: $('#numberValue').val()
})
但它编码$('#numberValue').val()为String.
如何将其编码为Number?