implement playing with howler

This commit is contained in:
Jonas Heinrich 2020-10-17 20:17:24 +02:00
parent 355073fc91
commit d100c5d9a4

View File

@ -18,6 +18,7 @@ import Breadcrumbs from '@nextcloud/vue/dist/Components/Breadcrumbs'
import Breadcrumb from '@nextcloud/vue/dist/Components/Breadcrumb'
import Navigation from './Navigation'
import Table from './Table'
import { Howl } from 'howler'
export default {
name: 'Main',
@ -36,8 +37,15 @@ export default {
mounted() {
this.loadStations()
this.scroll()
this.play()
},
methods: {
play() {
const sound = new Howl({
src: ['http://stream.srg-ssr.ch/m/drsvirus/mp3_128'],
})
sound.play()
},
loadStations() {
const vm = this
this.$jquery.ajax({