Element.prototype.removeAttribute doesn't work as expected
Reported by
hakerh403@gmail.com,
Jul 14
|
||||||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.87 Safari/537.36 Steps to reproduce the problem: 1. Run the provided test-case script 2. Observe that "1" is printed instead of "0" What is the expected behavior? 0 should be printed always. What went wrong? Number "1" is printed 90% of times. Only 10% of times (and only if devtools are open and the "Elements" tab is active) the script prints number "0". In Firefox it always prints "0" as expected. Did this work before? N/A Chrome version: 67.0.3396.87 Channel: stable OS Version: 6.3 Flash Version: /
,
Jul 17
As this is happening when devtools is open, can devtools team take a look at this first?
,
Jul 17
,
Jul 18
As per comment #1 able to reproduce the issue on 60.0.3112.32(M-60),reported version 67.0.3396.87 and latest chrome canary 69.0.3494.0 on Windows 10. This is a non-regression issue as it is observed from M60 old builds. Hence, marking it as untriaged to get more inputs from dev team. Thanks...!!
,
Jul 26
@kochi -- this happens when devtools are open, but it also happens without devtools :-)
,
Jul 30
Sounds a bug of attribute synchronization, which delays serialization of element.style changes. |
||||||
►
Sign in to add a comment |
||||||
Comment 1 by woxxom@gmail.com
, Jul 14Seems to happen only with the "style" attribute. Observed since at least Chrome 30, also in Canary. Simplified code: <body> <script> document.body.style.opacity = '0'; document.body.removeAttribute('style'); document.body.textContent = document.body.hasAttribute('style') ? 'FAIL' : 'OK'; </script> </body>