How to use the estraverse.Syntax.ClassDeclaration function in estraverse

To help you get started, we’ve selected a few estraverse examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github graalvm / graaljs / tools / eslint / node_modules / eslint-scope / lib / referencer.js View on Github external
visitClass(node) {
        if (node.type === Syntax.ClassDeclaration) {
            this.currentScope().__define(node.id,
                    new Definition(
                        Variable.ClassName,
                        node.id,
                        node,
                        null,
                        null,
                        null
                    ));
        }

        // FIXME: Maybe consider TDZ.
        this.visit(node.superClass);

        this.scopeManager.__nestClassScope(node);
github aduranil / django-channels-react-multiplayer / frontend / node_modules / eslint-scope / lib / referencer.js View on Github external
visitClass(node) {
        if (node.type === Syntax.ClassDeclaration) {
            this.currentScope().__define(node.id,
                    new Definition(
                        Variable.ClassName,
                        node.id,
                        node,
                        null,
                        null,
                        null
                    ));
        }

        // FIXME: Maybe consider TDZ.
        this.visit(node.superClass);

        this.scopeManager.__nestClassScope(node);
github vincentdchan / webpack-deep-scope-analysis-plugin / packages / deep-scope-analyser / src / referencer.ts View on Github external
public visitClass(node: ESTree.Class) {
    if (node.type === Syntax.ClassDeclaration) {
      this.currentScope!.__define(
        node.id!,
        new Definition(VariableType.ClassName, node.id, node),
      );
    }

    // FIXME: Maybe consider TDZ.
    this.visit(node.superClass!);

    this.scopeManager.__nestClassScope(node);

    if (node.id) {
      this.currentScope!.__define(
        node.id,
        new Definition(VariableType.ClassName, node.id, node),
      );
github elastic / timelion / node_modules / gulp-eslint / node_modules / eslint / node_modules / escope / lib / referencer.js View on Github external
value: function visitClass(node) {
                if (node.type === Syntax.ClassDeclaration) {
                    this.currentScope().__define(node.id, new Definition(Variable.ClassName, node.id, node, null, null, null));
                }

                // FIXME: Maybe consider TDZ.
                this.visit(node.superClass);

                this.scopeManager.__nestClassScope(node);

                if (node.id) {
                    this.currentScope().__define(node.id, new Definition(Variable.ClassName, node.id, node));
                }
                this.visit(node.body);

                this.close(node);
            }
        },
github sx1989827 / DOClever / Desktop / node_modules / escope / src / referencer.js View on Github external
visitClass(node) {
        if (node.type === Syntax.ClassDeclaration) {
            this.currentScope().__define(node.id,
                    new Definition(
                        Variable.ClassName,
                        node.id,
                        node,
                        null,
                        null,
                        null
                    ));
        }

        // FIXME: Maybe consider TDZ.
        this.visit(node.superClass);

        this.scopeManager.__nestClassScope(node);
github angelozerr / tern.java / core / ternjs / node_modules / tern-eslint / node_modules / eslint / node_modules / escope / lib / referencer.js View on Github external
value: function visitClass(node) {
                if (node.type === Syntax.ClassDeclaration) {
                    this.currentScope().__define(node.id, new Definition(Variable.ClassName, node.id, node, null, null, null));
                }

                // FIXME: Maybe consider TDZ.
                this.visit(node.superClass);

                this.scopeManager.__nestClassScope(node);

                if (node.id) {
                    this.currentScope().__define(node.id, new Definition(Variable.ClassName, node.id, node));
                }
                this.visit(node.body);

                this.close(node);
            }
        },
github estools / escope / src / referencer.js View on Github external
visitClass(node) {
        if (node.type === Syntax.ClassDeclaration) {
            this.currentScope().__define(node.id,
                    new Definition(
                        Variable.ClassName,
                        node.id,
                        node,
                        null,
                        null,
                        null
                    ));
        }

        // FIXME: Maybe consider TDZ.
        this.visit(node.superClass);

        this.scopeManager.__nestClassScope(node);
github sx1989827 / DOClever / node_modules / eslint-scope / lib / referencer.js View on Github external
visitClass(node) {
        if (node.type === Syntax.ClassDeclaration) {
            this.currentScope().__define(node.id,
                    new Definition(
                        Variable.ClassName,
                        node.id,
                        node,
                        null,
                        null,
                        null
                    ));
        }

        // FIXME: Maybe consider TDZ.
        this.visit(node.superClass);

        this.scopeManager.__nestClassScope(node);
github miccferr / leaflet-store-locator / old / node_modules / eslint / node_modules / escope / lib / referencer.js View on Github external
value: function visitClass(node) {
                if (node.type === Syntax.ClassDeclaration) {
                    this.currentScope().__define(node.id, new Definition(Variable.ClassName, node.id, node, null, null, null));
                }

                // FIXME: Maybe consider TDZ.
                this.visit(node.superClass);

                this.scopeManager.__nestClassScope(node);

                if (node.id) {
                    this.currentScope().__define(node.id, new Definition(Variable.ClassName, node.id, node));
                }
                this.visit(node.body);

                this.close(node);
            }
        },
github graalvm / graaljs / tools / node_modules / eslint / node_modules / eslint-scope / lib / referencer.js View on Github external
visitClass(node) {
        if (node.type === Syntax.ClassDeclaration) {
            this.currentScope().__define(node.id,
                new Definition(
                    Variable.ClassName,
                    node.id,
                    node,
                    null,
                    null,
                    null
                ));
        }

        this.visit(node.superClass);

        this.scopeManager.__nestClassScope(node);

        if (node.id) {