Welcome aboard! We are happy you are here and wish you good net-raft!
<!DOCTYPE html>
<html>
<body>
<button onclick="myfunction()">replace</button>
<div id="test">This is angularjs!</div>
<script>
function myfunction() {
var str1 = document.getElementById("test").innerHTML;
var txt1 = str1.replace(/angularjs/g,"javascript");
document.getElementById("test").innerHTML = txt1;
}
</script>
</body>
</html> 
The most helpful JAVASCRIPT solutions