Trim white space
Remove leading and trailing white space

Script key: Remove leading and trailing white space

Posted by @nuclearzenfire

Install

Details

Label Trim white space
Voice Over Remove leading and trailing white space
Script
var sel = getText();
var res = sel.replace(/^[ \t]+|[ \t]+$/gm,'');
setText(res);

Advanced

Keyboard shortcut None
Hide key Yes

Discussion

comments powered by Disqus