How do you trim a string in Javascript

Posted by Andre Scott | Updated on

JavaScript provided a trim method on string types to trim any whitespaces present at the beginning or ending of the string.

If your browser(


If you like this question & answer and want to contribute, then write your question & answer and email to freewebmentor[@]gmail.com. Your question and answer will appear on FreeWebMentor.com and help other developers.

Related Questions & Answers