on develop help sign in
Fix issue with namespaces in hydration
commit1f435b234da76a07da5dcc53751b59d0ddbb0147 authorJimmy Hartzell <jimmy.hartzell@obsidian.systems> dateMon 27 Jan 2020, 12:46 (7 years ago) parent27720c0
1 file changed+4−9
reflex-dom-core/src/Reflex/Dom/Builder/Immediate.hs+4−9
reflex-dom-core/src/Reflex/Dom/Builder/Immediate.hs+4−9
@@ -767,15 +767,10 @@ hydrateElement elementTag cfg child = do
767767 let skipAttr = "data-hydration-skip" :: DOM.JSString
768768 ssrAttr = "data-ssr" :: DOM.JSString
769769 shouldSkip :: DOM.Element -> HydrationRunnerT t m Bool
770− shouldSkip e = case cfg ^. namespace of
771− Nothing -> do
772− skip <- hasAttribute e skipAttr
773− ssr <- hasAttribute e ssrAttr
774− pure $ skip || not ssr
775− Just ns -> do
776− skip <- hasAttributeNS e (Just ns) skipAttr
777− ssr <- hasAttributeNS e (Just ns) ssrAttr
778− pure $ skip || not ssr
770+ shouldSkip e = do
771+ skip <- hasAttribute e skipAttr
772+ ssr <- hasAttribute e ssrAttr
773+ pure $ skip || not ssr
779774 childDom <- liftIO $ readIORef childDelayedRef
780775 let rawCfg = extractRawElementConfig cfg
781776 doc <- askDocument