Added handlebars.

This commit is contained in:
Andrew Lalis 2018-09-25 14:26:44 +02:00
parent 4df42ed503
commit abc5a6f061
2 changed files with 21 additions and 2 deletions

View File

@ -262,10 +262,11 @@
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
<script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
<script>window.jQuery || document.write('<script src="js/vendor/jquery-1.11.2.min.js"><\/script>')</script>
<script src="js/vendor/bootstrap.min.js"></script>
<script src="js/handlebars-v4.0.12.js"></script>
<script src="js/main.js"></script>
<script src="js/load_reviews.js"></script>
</body>
</html>

View File

@ -0,0 +1,18 @@
var $ = jQuery;
function displayReviews(reviews) {
}
function loadReviews () {
$.ajax({
url: "http://localhost:8000/api/postings/",
method: "GET"
}).done(function (response) {
displayReviews(response);
}).fail(function (response) {
console.log(response);
})
}
loadReviews();