more minor tidying

pull/1839/head
Rich Harris 7 years ago
parent a09dc36ea5
commit f33c5ee8d2

@ -68,7 +68,6 @@ export default class Component {
module_script: Node;
imports: Node[] = [];
hasComponents: boolean;
module_javascript: string;
javascript: string;
@ -90,18 +89,18 @@ export default class Component {
file: string;
locate: (c: number) => { line: number, column: number };
// TODO this does the same as component.locate! remove one or the other
locator: (search: number, startIndex?: number) => {
line: number,
column: number
};
stylesheet: Stylesheet;
userVars: Set<string> = new Set();
templateVars: Map<string, string> = new Map();
aliases: Map<string, string> = new Map();
usedNames: Set<string> = new Set();
init_uses_self = false;
locator: (search: number, startIndex?: number) => {
line: number,
column: number
};
constructor(
ast: Ast,

@ -28,8 +28,6 @@ export default class EventHandler extends Node {
this.expression = new Expression(component, this, template_scope, info.expression);
this.usesContext = this.expression.usesContext;
} else {
component.init_uses_self = true;
const name = component.getUniqueName(`${this.name}_handler`);
component.declarations.push(name);

@ -25,8 +25,6 @@ export default class InlineComponent extends Node {
component.template_references.add(info.name);
}
component.hasComponents = true;
this.name = info.name;
this.expression = this.name === 'svelte:component'

@ -272,7 +272,6 @@ function getValueFromDom(
if (name === 'group') {
const bindingGroup = getBindingGroup(renderer, binding.node.expression.node);
if (type === 'checkbox') {
renderer.component.init_uses_self = true;
return `@getBindingGroupValue($$self.$$.binding_groups[${bindingGroup}])`;
}

Loading…
Cancel
Save