slice last char code example
Example 1: how to remove lasr char from string in javascript
str=str.slice(0, -1);
Example 2: how to remove the last character from a string in javascript
var str = "Hello TecAdmin!";
var newStr = str.slice(0, -1);
str=str.slice(0, -1);
var str = "Hello TecAdmin!";
var newStr = str.slice(0, -1);