pull/12335/head
Rich Harris 2 years ago
commit 2d41103d95

@ -19,7 +19,6 @@ import { set_should_intro } from '../../render.js';
import { current_each_item, set_current_each_item } from './each.js'; import { current_each_item, set_current_each_item } from './each.js';
import { current_component_context, current_effect } from '../../runtime.js'; import { current_component_context, current_effect } from '../../runtime.js';
import { DEV } from 'esm-env'; import { DEV } from 'esm-env';
import { noop } from '../../../shared/utils.js';
import { EFFECT_TRANSPARENT } from '../../constants.js'; import { EFFECT_TRANSPARENT } from '../../constants.js';
/** /**
@ -143,9 +142,6 @@ export function element(node, get_tag, is_svg, render_fn, get_namespace, locatio
/** @type {Effect} */ (current_effect).nodes = { start: element, end: element }; /** @type {Effect} */ (current_effect).nodes = { start: element, end: element };
anchor.before(element); anchor.before(element);
// See below
return noop;
}); });
} }
@ -154,10 +150,6 @@ export function element(node, get_tag, is_svg, render_fn, get_namespace, locatio
set_should_intro(true); set_should_intro(true);
set_current_each_item(previous_each_item); set_current_each_item(previous_each_item);
// Inert effects are proactively detached from the effect tree. Returning a noop
// teardown function is an easy way to ensure that this is not discarded
return noop;
}, EFFECT_TRANSPARENT); }, EFFECT_TRANSPARENT);
if (was_hydrating) { if (was_hydrating) {

Loading…
Cancel
Save