on develop help sign in
Add HasWebView for backwards compatibility
commit64508a55eeb057d679be56cfb8e4c2b95e3b1eb5 authorHamish Mackenzie <Hamish.K.Mackenzie@googlemail.com> dateSun 18 Dec 2016, 20:44 (10 years ago) parent04a33a6
1 file changed+5−1
reflex-dom-core/src/Foreign/JavaScript/TH.hs+5−1
reflex-dom-core/src/Foreign/JavaScript/TH.hs+5−1
@@ -3,7 +3,6 @@
33{-# LANGUAGE ExistentialQuantification #-}
44{-# LANGUAGE FlexibleContexts #-}
55{-# LANGUAGE FlexibleInstances #-}
6−{-# LANGUAGE ForeignFunctionInterface #-}
76{-# LANGUAGE FunctionalDependencies #-}
87{-# LANGUAGE GeneralizedNewtypeDeriving #-}
98{-# LANGUAGE MultiParamTypeClasses #-}
@@ -15,7 +14,9 @@
1514{-# LANGUAGE TypeFamilies #-}
1615{-# LANGUAGE TypeSynonymInstances #-}
1716{-# LANGUAGE UndecidableInstances #-}
17+{-# LANGUAGE ConstraintKinds #-}
1818#ifdef __GHCJS__
19+{-# LANGUAGE ForeignFunctionInterface #-}
1920{-# LANGUAGE JavaScriptFFI #-}
2021#endif
2122module Foreign.JavaScript.TH ( module Foreign.JavaScript.TH
@@ -92,6 +93,9 @@ class Monad m => HasJSContext m where
9293 type JSContextPhantom m :: *
9394 askJSContext :: m (JSContextSingleton (JSContextPhantom m))
9495
96+type HasWebView = HasJSContext
97+-- Not sure if we should deprecate this {-# DEPRECATED HasWebView "Use HasJSContext" #-}
98+
9599instance HasJSContext m => HasJSContext (ReaderT r m) where
96100 type JSContextPhantom (ReaderT r m) = JSContextPhantom m
97101 askJSContext = lift askJSContext