Disable spell-checking on HTML textfields

前端 未结 6 959
萌比男神i
萌比男神i 2020-11-28 02:27

Can I somehow disable spell-checking on HTML textfields (as seen in e.g. Safari)?

6条回答
  •  清酒与你
    2020-11-28 02:52

    While specifying spellcheck="false" in the < tag > will certainly disable that feature, it's handy to be able to toggle that functionality on and off as needed after the page has loaded. So here's a non-jQuery way to set the spellcheck attribute programmatically:

提交回复
热议问题