Update main.js

When no text is selected the word at the current cursor position will be selected. This way there is no need anymore to select the word to search for, simply putting the cursor somewhere in the word is sufficient.
Merge pull request #1 from DannyMoerkerke/master

Update main.js to allow querying the word at current cursor position, even when not selected.