packages feed

ghcjs-dom-javascript-0.10.0.0: src/GHCJS/DOM/JSFFI/Generated/CustomElementConstructor.hs

{-# OPTIONS_GHC -fno-warn-unused-imports #-}
-- | Generated by dom-gen from html (webref). Do not edit.
module GHCJS.DOM.JSFFI.Generated.CustomElementConstructor
       (newCustomElementConstructor, newCustomElementConstructorSync, newCustomElementConstructorAsync, CustomElementConstructor)
       where
import Prelude ((.), (==), (>>=), (<$>), (++), Bool(..), Maybe(..), IO, Int, Word, Double, Float)
import qualified Prelude as P
import Control.Monad (void)
import GHCJS.Types (JSVal, JSString)
import GHCJS.Foreign (jsUndefined, jsNull)
import Data.Coerce (coerce)
import GHC.JS.Foreign.Callback (OnBlocked(..), syncCallback, asyncCallback)
import GHCJS.DOM.Types
import GHCJS.DOM.JSFFI.Generated.Enums

newCustomElementConstructor :: (MonadDOM m) => (IO ()) -> m CustomElementConstructor
newCustomElementConstructor callback = liftDOM ((CustomElementConstructor . coerce) <$> syncCallback ContinueAsync callback)

newCustomElementConstructorSync :: (MonadDOM m) => (IO ()) -> m CustomElementConstructor
newCustomElementConstructorSync callback = liftDOM ((CustomElementConstructor . coerce) <$> syncCallback ThrowWouldBlock callback)

newCustomElementConstructorAsync :: (MonadDOM m) => (IO ()) -> m CustomElementConstructor
newCustomElementConstructorAsync callback = liftDOM ((CustomElementConstructor . coerce) <$> asyncCallback callback)