Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
constructor() {
super();
const visitor = new Visitor();
visitor.onSurfaceDrawError = (error: Error) => {
this.setState({ error });
return true;
};
visitor.onSurfaceDrawEnd = () => this.setState({ error: null });
this.state = { error: null, visitor };
}
constructor() {
super();
const visitor = new Visitor();
visitor.onSurfaceDrawError = (error: Error) => {
this.setState({ error });
return true;
};
visitor.onSurfaceDrawEnd = () => this.setState({ error: null });
this.state = { error: null, visitor };
};
constructor() {
super();
const visitor = new Visitor();
visitor.onSurfaceDrawError = (error: Error) => {
this.setState({ error });
return true;
};
visitor.onSurfaceDrawEnd = () => this.setState({ error: null });
this.state = { error: null, visitor };
}