12 lines · 271 bytes
1//go:build js
2// +build js
3
4package beeep
5
6// Alert displays a desktop notification and plays a beep.
7func Alert(title, message, appIcon string) error {
8 if err := Notify(title, message, appIcon); err != nil {
9 return err
10 }
11 return Beep(DefaultFreq, DefaultDuration)
12}