on develop help sign in
clear rootElement and append document fragment in favor of optimistically using replaceChild
a7f0e7dLuigy Leon
src/Reflex/Dom/Internal.hs+2−4
@@ -128,10 +128,8 @@ attachWidgetFragment' rootElement wv w = do
128 _ <- fire (catMaybes mes) $ return ()
128 _ <- fire (catMaybes mes) $ return ()
129 liftIO $ forM_ ers $ \(_ :=> TriggerInvocation _ cb) -> cb
129 liftIO $ forM_ ers $ \(_ :=> TriggerInvocation _ cb) -> cb
130 return ()
130 return ()
131− -- XXX should it `setInnerHtml rootElement ""` first? looks good without it
131+ setInnerHTML rootElement $ Just (""::String)
132− -- FIXME this assumes the `rootElement` already has a child
133− Just prerender <- getFirstChild rootElement
134− replaceChild rootElement (Just df) (Just prerender)
132+ appendChild rootElement (Just df)
135 return (result, fc)
133 return (result, fc)
136
134
137data AppInput t = AppInput
135data AppInput t = AppInput