You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've never written any sort of linting rule before so this is all new to me, so I appologize if I seem like a newb but i'm running into some trouble. First off I recognize that my rule right now will just always fail, that's just my first step...
After transpiling the rule and getting it to run i hit the following error:
TypeError: Cannot read property 'call' of undefined
at FileNameValidatorWalker.visitClassDeclaration (C:\extras\projectx\authoring-ui\node_modules\ng2lint\dist\src\fileNameBase.js:44:37)
at FileNameValidatorWalker.SyntaxWalker.visitNode (C:\extras\projectx\authoring-ui\node_modules\tslint\lib\language\walker\syntaxWalker.js:255:22)
at C:\extras\projectx\authoring-ui\node_modules\tslint\lib\language\walker\syntaxWalker.js:441:63
at visitEachNode (C:\extras\projectx\authoring-ui\node_modules\typescript\lib\typescript.js:7209:30)
at Object.forEachChild (C:\extras\projectx\authoring-ui\node_modules\typescript\lib\typescript.js:7360:24)
at FileNameValidatorWalker.SyntaxWalker.walkChildren (C:\extras\projectx\authoring-ui\node_modules\tslint\lib\language\walker\syntaxWalker.js:441:12)
at FileNameValidatorWalker.SyntaxWalker.visitSourceFile (C:\extras\projectx\authoring-ui\node_modules\tslint\lib\language\walker\syntaxWalker.js:181:14)
at FileNameValidatorWalker.SyntaxWalker.visitNode (C:\extras\projectx\authoring-ui\node_modules\tslint\lib\language\walker\syntaxWalker.js:396:22)
at FileNameValidatorWalker.SyntaxWalker.walk (C:\extras\projectx\authoring-ui\node_modules\tslint\lib\language\walker\syntaxWalker.js:7:14)
at Rule.AbstractRule.applyWithWalker (C:\extras\projectx\authoring-ui\node_modules\tslint\lib\language\rule\abstractRule.js:19:16)
which is just:
_super.visitClassDeclaration.call(this, node);
which is exactly the same as what is in (transpiled version of) the selectorNameBase.ts file that I based this on.
Thoughts?
The text was updated successfully, but these errors were encountered:
If you are referencing _super with _ prefix, you should remove it.
Should be: super.visitClassDeclaration.call.... Another possible mistake could be if you haven't extended the base class, i.e. class FileNameValidatorWalker extends Lint.RuleWalker
I've started a fork with some changes around creating a fileNameBase rule with the idea of eventually getting to supporting the styleguide's concept of kebab-case (configurable of course) with .component.ts suffix's.
I've never written any sort of linting rule before so this is all new to me, so I appologize if I seem like a newb but i'm running into some trouble. First off I recognize that my rule right now will just always fail, that's just my first step...
After transpiling the rule and getting it to run i hit the following error:
which is just:
_super.visitClassDeclaration.call(this, node);
which is exactly the same as what is in (transpiled version of) the
selectorNameBase.ts
file that I based this on.Thoughts?
The text was updated successfully, but these errors were encountered: