No-Library (pure JS), HTML, CSS, JavaScript
For StackOverflow question http://stackoverflow.com/questions/37054885/keep-text-selected-when-focus-input