Give all HTML button elements a type#18517
Conversation
The HTML button elements we use are all regular buttons that don't submit form data to a server. According to https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#notes those buttons should all have their type set to `button` explicitly, but we only do that a handful of them. This commit fixes the issue by consistently giving all our buttons the `button` type. Co-authored-by: Calixte Denizet <calixte.denizet@gmail.com>
|
I discovered this issue thanks to a warning in Edge console. |
|
I have verified that all buttons now have the This can be compared to master where the command found 60 occurrences instead: |
|
/botio-linux preview |
From: Bot.io (Linux m4)ReceivedCommand cmd_preview from @timvandermeij received. Current queue size: 0 Live output at: http://54.241.84.105:8877/ab493312e211266/output.txt |
From: Bot.io (Linux m4)SuccessFull output at http://54.241.84.105:8877/ab493312e211266/output.txt Total script time: 1.21 mins Published |
|
/botio integrationtest |
From: Bot.io (Windows)ReceivedCommand cmd_integrationtest from @timvandermeij received. Current queue size: 0 Live output at: http://54.193.163.58:8877/957a1d6e95a1158/output.txt |
From: Bot.io (Linux m4)ReceivedCommand cmd_integrationtest from @timvandermeij received. Current queue size: 0 Live output at: http://54.241.84.105:8877/144226ddc948f48/output.txt |
From: Bot.io (Linux m4)SuccessFull output at http://54.241.84.105:8877/144226ddc948f48/output.txt Total script time: 8.43 mins
|
From: Bot.io (Windows)FailedFull output at http://54.193.163.58:8877/957a1d6e95a1158/output.txt Total script time: 17.70 mins
|
The HTML button elements we use are all regular buttons that don't submit form data to a server. According to
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#notes those buttons should all have their type set to
buttonexplicitly, but we only do that a handful of them. This commit fixes the issue by consistently giving all our buttons thebuttontype.Extracts a part of #18385.