0
I am creating a web app using EMBER and want to use in a certain place the Listjs to list discussions but not working. follows the code:
function(List){
var options = {
listClass: 'list',
valueNames: [ 'discussion' ]
};
var discussionList = new List('matheus', options);
});
});
<script type="text/x-handlebars" id="discussions">
<div class="large-4 columns forum-discussions" id="matheus">
<!-- Menu de funcionalidades -->
<div class="row">
<div class="larger-2 columns text-center">
<!-- Search -->
<a href="#" class="button round option" id="search"><i class="fa fa-search"></i></a>
<!-- New discussion -->
{{#link-to 'discussions.new' classNames="button round option"}}
<i class="fa fa-plus"></i>
{{/link-to}}
</div>
<!-- toggle effect begin-->
<!--search-->
<div class="forum-search forum-events">
<input type="text" class="search" value="" placeholder="Buscar Discussão">
</div>
<!-- end of toggle effect-->
<hr class="forum-divisor">
</div>
<!-- Listagem de discussões -->
<div class="row">
<div class="large-12 forum-discussions-list">
<ul class="list">
{{#each discussion in model}}
{{#link-to 'discussion' discussion}}
<li>
<div class="larger-4 forum-photo">
<!--photo-->
</div>
<div>
<p class="discussion">{{discussion.title}}</p>
</div>
</li>
{{/link-to}}
<hr class="forum-divisor">
{{/each}}
</ul>
</div>
</div>
</div>
{{outlet}}
</script>
http://answall.com/help/mcve
– Renan Gomes
Part of the beginning of javascript is missing. Complete the snippet to help us help you.
– Guilherme Nagatomo