how to cut a string uptil specific character javascript

Solutions on MaxInterview for how to cut a string uptil specific character javascript by the best coders in the world

showing results for - "how to cut a string uptil specific character javascript"
Stefania
18 Mar 2016
1var str = "Abc: Lorem ipsum sit amet";
2str = str.split(":").pop();
3 // OR
4str = str.split(":").shift();