I want to call custom javascript function with jquery selector but this say Uncaught TypeError: $(...).makeRed is not a function
<!DOCTYPE html>
<html>
<head>
<title></title>
</head>
<body>
<h3 id="ch">Hello Wrld</h3>
</body>
</html>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
<script>
$(document).ready(function(){
$.fn.makeRed = function(){
this.html('welcome to all');
return this;
}
});
$('#ch').makeRed();
</script>