fknop/angular-pipes

Ionic2 - Can't exclude node_modules/angular-pipes/ from tslint

Closed this issue · 1 comments

I have an issue with tslint on Ionic2 with this module. I'm using a lot of modules on Ionic2 and I never had to face this issue.

I have many rules on my tslint file, and tslint is not supposed to check the files into node_modules, but I have all errors from this module. Like this one :

 tslint: .../node_modules/angular-pipes/src/string/repeat.pipe.ts, line: 9
            Type declaration of 'any' loses type-safety. Consider replacing it with a more precise type, the empty type
            ('{}'), or suppress this occurrence.

       L9:  transform (input: any, times: number = 1, characters: string = ''): any {

I tried to remove it by using tsconfig or tslint files, but nothing can remove the module from tslint checking.

In the tsconfig :

  "include": [
    "src/**/*.ts"
  ],
  "exclude": [
    "node_modules",
    "e2e",
    "**/*.spec.ts"
  ],

The path 'node_modules/angular-pipes/src/' contains 'src/**/*.ts', so it could be checked but normaly it's a relative path so it wouldn't. And the exclude rule should remove it...

So I don't know if you can try something, and if the problem is on your side, but I couldn't find anything on internet relative to that issue.

Many thanks.

fknop commented

It's probably an issue with tslint which doesn't exclude the folder as expected.