Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /html/semantics/forms/textfieldselection/textarea-selection-while-parsing.xhtml - WPT Dashboard Interop Dashboard
<?xml version="1.0"?>
<body>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<textarea>
a
<script>document.querySelector('textarea').value = 'ggg';</script>
b
</textarea>
<script>
test(() => {
let ta = document.querySelector('textarea');
assert_equals(ta.selectionStart, 3);
assert_equals(ta.selectionEnd, 3);
}, 'Value setter while parsing textarea children should move ' +
'selection{Start,End} to the end');
</script>
</body>
</html>