deconflict variable for inline component instance

pull/4792/head
Conduitry 5 years ago
parent c743e72a1e
commit 592b55088c

@ -64,14 +64,13 @@ export default class InlineComponentWrapper extends Wrapper {
}
});
this.var = {
type: 'Identifier',
name: (
this.var = block.get_unique_name(
(
this.node.name === 'svelte:self' ? renderer.component.name.name :
this.node.name === 'svelte:component' ? 'switch_instance' :
sanitize(this.node.name)
).toLowerCase()
};
);
if (this.node.children.length) {
this.node.lets.forEach(l => {

Loading…
Cancel
Save