I'm having an issue with a basic angular file that is being served by django.. I can't seem to bind angular views.py
def home (request):
return render(request,'index.html',{})
index.html
{% load staticfiles %}
<!DOCTYPE html>
<html>
<script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js"></script>
<body>
<div ng-app="">
<p>Input something in the input box:</p>
<p>Name : <input type="text" ng-model="name" placeholder="Enter name here"></p>
<h1>Hello {{name}}</h1>
</div>
</body>
</html>
Even though this seems straightforward, my ng-model="name"
doesn't seem to bind with the Hello {{name}}
If I open my index.html as a standalone HTML file, it works fine, but not when used within django
Can anyone assist with why this might be happening?
Appreciate any help in advance