rangy
rangy copied to clipboard
Expand does not exist on RangySelection. Nor does expand show in getSelection()
trafficstars
I am trying to use var selTxt = rangy.getSelection().expand("word"). I get an error saying expand does not exist on rangySelection
Make sure youre including the textrange library: rangy/lib/rangy-textrange.js
I did have it included. It still doesn't work.
seems to behave without the chaining:
let selection = rangy.getSelection();
selection.expand("word");