0.2.0 • Published 10 years ago
expand-selection v0.2.0
expand-selection
Add matching text to the current DOM selection.
API
expandSelection(string, [opts])
expandSelection([selection], [opts])
Searches document for string or selection.toString() and selects matching ranges.
selection defaults to window.getSelection().
Returns Selection object.
opts.clear
Clears current selection before updating. Defaults to false.
opts.ignoreCase
Whether to ignore case while attempting a match in a string. Defaults to false.
Install
npm install expand-selectionLicense
MIT

