how to make sound with notification database in filament
this is my code "
@php
$notificationss = DB::table('notifications')->get();
@endphp
@if(count($notificationss) >=1 )
<script>
function playNotificationSound() {
const audio = new Audio('/sounds/notification.wav');
audio.play();
}
</script>
<div class="notification">
<script>
playNotificationSound();
setInterval(() => {
playNotificationSound()
}, 10000);
</script>
</div>
@endif"
how to inject this code in filament ?
@php
$notificationss = DB::table('notifications')->get();
@endphp
@if(count($notificationss) >=1 )
<script>
function playNotificationSound() {
const audio = new Audio('/sounds/notification.wav');
audio.play();
}
</script>
<div class="notification">
<script>
playNotificationSound();
setInterval(() => {
playNotificationSound()
}, 10000);
</script>
</div>
@endif"
how to inject this code in filament ?