on develop help sign in
Avoid runWithReplace call when hydrating

This simplifies things, and avoids creating extra events. /cc @tomsmalley @ryantrinkle

commitf51f773df627dfde87da0d2ee5a2d8f2fb5ee9b0 authorMatthew Bauer <mjbauer95@gmail.com> dateWed 12 Feb 2020, 12:23 (7 years ago) parent94c2607
1 file changed+1−2
reflex-dom-core/src/Reflex/Dom/Builder/Immediate.hs+1−2
reflex-dom-core/src/Reflex/Dom/Builder/Immediate.hs+1−2
@@ -318,8 +318,7 @@ addHydrationStepWithSetup :: (Adjustable t m, MonadIO m) => m a -> (a -> Hydrati
318318addHydrationStepWithSetup setup f = getHydrationMode >>= \case
319319 HydrationMode_Immediate -> pure ()
320320 HydrationMode_Hydrating -> do
321− switchover <- HydrationDomBuilderT $ asks _hydrationDomBuilderEnv_switchover
322− (s, _) <- lift $ runWithReplace setup $ return () <$ switchover
321+ s <- lift setup
323322 addHydrationStep (f s)
324323
325324-- | Add a hydration step