I can not get the text from my text box:
Very simple text area:
<textarea id="message" placeholder="Type your text here..."></textarea>
My dart code is:
var area = document.query('#message'); document.query("#send").on.click.add((e) { print('send ${area.text}'); });
When I write a message in the field and click send, just show:
send
I do not understand why my message does not print. "text" is not a valid field? (same problem with innerHtml) When I add
area.text = 'Hello';
The message is displayed in the text box, and printing is good.
source share