I have a very small query. I tried using concat, charAt, slice and whatnot but I didn\'t get how to do it.
Here is my string:
var str1 = \"Notion,Data,I
This isn't elegant but it's reusable.
term(str, char)
str: string needing proper termination
str:
char: character to terminate string with
char:
var str1 = "Notion,Data,Identity,"; function term(str, char) { var xStr = str.substring(0, str.length - 1); return xStr + char; } console.log(term(str1,'.'))