Inconsistency between DDC and dart2js the Selection class did not implement the toString method to return the selected text, at the moment toString returns the selected text only in DDC and in Dart2JS it returns "Instance of 'Selection'"
Dart version 2.12.4
var sel = window.getSelection();
var textSel = sel.toString();
print('seleção $textSel');