CodePen

HTML

            
              <textarea>Holy smurfs!</textarea><br>
<button>Move cursor to end of textarea</button>
            
          
!
via HTML Inspector

CSS

            
              
            
          
!
? ?
? ?
Must be a valid URL.
+ add another resource
via CSS Lint

JS

            
              $("button").on("click", function() {
  
  // cache textarea as we need it more than once
  var textarea = $("textarea"),
      
      // save old value as we need to clear it
      val = textarea.val();
  
  // if the value doesn't end in a space, add one
  if (val.charAt(val.length-1) != " ") {
    val += " ";
  }
  
  // focus textarea, clear value, re-apply
  textarea
    .focus()
    .val("")
    .val(val);
});
            
          
!
Must be a valid URL.
+ add another resource
via JS Hint
Loading ..................