提交数据时 "id" 与 HTML 表单元素上的 "name" 属性的命名约定

Naming convention for the "id" vs "name" attribute on HTML form elements when submitting data

HTML 表单元素 ID 与 name 属性是否有建议的命名约定?

我具体指的是提交表单并使用 jQuery.serializeArrays() 捕获似乎提供 {"name":"", "value":""} 对的数据。

您可以在此处找到 Google 的风格指南:

4.1.2 ID and Class Naming