cinema/filter.riot
2022-04-01 23:57:59 +02:00

20 lines
410 B
Plaintext

<sorting>
<form onsubmit="{filteing}">
<button onclick={filteing} value=""&sort_by="vote_average.desc">Mieux notés</button>
<button onclick={filteing}>Plus populaires</button>
</form>
<script>
export default
{
async filteing(e)
{
let data = await this.sa.sorting(e.target.value)
this.props.updateListFilm(data.results)
//console.log(data)
}
}
</script>
</sorting>