Ok, I see
http://laytheme.com/documentation.html#custom-javascript
You could also fetch your data using wp-api. http://v2.wp-api.org/
That's what lay theme uses.
In this case it's pretty slow, cause first I fetch all posts, then I fetch each featured image (project thumbnails) and that just takes long. :/
<script> Frontend.GlobalEvents.on("newpageshown", function(layoutObj, type, obj){ if(type == "page" && obj.id == 20){ //fetch projects jQuery.getJSON(frontendPassedData.wpapiroot+'wp/v2/posts/', function(result){ console.log(result); for(var i=0; i<result.length; i++){ var fi_id = result[i].featured_image; jQuery.getJSON(frontendPassedData.wpapiroot+'wp/v2/media/'+fi_id, function(result){ console.log(result); }); } }); } }); </script>But maybe you don't need all the featured images but just the project titles. That's faster:
<script> Frontend.GlobalEvents.on("newpageshown", function(layoutObj, type, obj){ if(type == "page" && obj.id == 20){ //fetch projects jQuery.getJSON(frontendPassedData.wpapiroot+'wp/v2/posts/', function(result){ for(var i=0; i<result.length; i++){ console.log(result[i].title.rendered); } }); } }); </script>