Skip to content

Commit 8b031f8

Browse files
Drop deprecated use of RLProxy and SProxy (#144)
* Drop deprecated use of `RLProxy` * Also drop `SProxy`
1 parent 4fb54fd commit 8b031f8

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Diff for: src/React/Basic/Events.purs

+6-6
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@ module React.Basic.Events
1212
) where
1313

1414
import Prelude
15-
import Data.Symbol (class IsSymbol, SProxy(SProxy))
15+
import Data.Symbol (class IsSymbol)
1616
import Effect (Effect)
1717
import Effect.Uncurried (EffectFn1, mkEffectFn1)
1818
import Prim.Row as Row
1919
import Prim.RowList (class RowToList, RowList, Cons, Nil)
2020
import Record (delete, get, insert)
21-
import Type.Data.RowList (RLProxy(..))
21+
import Type.Proxy (Proxy(..))
2222

2323
-- | An event handler, which receives a `SyntheticEvent` and performs some
2424
-- | effects in return.
@@ -80,7 +80,7 @@ syntheticEvent :: EventFn SyntheticEvent SyntheticEvent
8080
syntheticEvent = identity
8181

8282
class Merge (rl :: RowList Type) fns a r | rl -> fns, rl a -> r where
83-
mergeImpl :: RLProxy rl -> Record fns -> EventFn a (Record r)
83+
mergeImpl :: Proxy rl -> Record fns -> EventFn a (Record r)
8484

8585
instance mergeNil :: Merge Nil () a () where
8686
mergeImpl _ _ = EventFn \_ -> {}
@@ -97,13 +97,13 @@ instance mergeCons ::
9797
mergeImpl _ fns =
9898
EventFn \a ->
9999
let
100-
EventFn inner = mergeImpl (RLProxy :: RLProxy rest) (delete l fns)
100+
EventFn inner = mergeImpl (Proxy :: Proxy rest) (delete l fns)
101101

102102
EventFn f = get l fns
103103
in
104104
insert l (f a) (inner a)
105105
where
106-
l = SProxy :: SProxy l
106+
l = Proxy :: Proxy l
107107

108108
-- | Merge multiple `EventFn` operations and collect their results.
109109
-- |
@@ -120,4 +120,4 @@ merge ::
120120
Merge fns_list fns a r =>
121121
Record fns ->
122122
EventFn a (Record r)
123-
merge = mergeImpl (RLProxy :: RLProxy fns_list)
123+
merge = mergeImpl (Proxy :: Proxy fns_list)

0 commit comments

Comments
 (0)