blob: b34960b818abe909fa1330fae04c6d91f1926a9c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
{-# LANGUAGE NoImplicitPrelude #-}
module Miso.FFI.Audio where
import GHCJS.Types
import Protolude
{-
Usage:
obj <- Miso.FFI.Document.getElementById "myAudioPlayer"
play obj
pause obj
-}
foreign import javascript unsafe "$1.play();"
play :: JSVal -> IO ()
foreign import javascript unsafe "$1.pause();"
pause :: JSVal -> IO ()
|