-
-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error: Cannot find ./src/rxjs.imports.ts #5
Comments
Regarding the error relating to |
@cartant yes, you can check it here: Although it has a main |
Thanks. Yeah, it sounds like that could be the problem. I think the path will need to be relative to whichever I would try specifying Either way, I'll improve the error message to include the absolute path that it's using to look for the file. |
Forgot to mention that I also tried Thanks a lot for looking into this! |
No worries. I'll have a look at it tomorrow. |
The problem is that the Angular CLI runs TSLint three times:
If the central imports file is not included in the tests, it's not available in the compiled TypeScript program that TSLint provides to the rules. You can fix the problem by importing import './rxjs.imports'; and in import '../src/rxjs.imports'; I'll improve the error thrown by the rule to better describe the situation. |
@cartant thank you so much, it works great now! |
No worries. |
@herkulano You might be interested in this issue and this comment. It introduces a somewhat cleaner way of making the |
@cartant I think you should add to the README:
As you've written above. My tests will complain about not finding the rxjs imports otherwise. |
@kamok The |
@cartant I have no idea why mine didn't work when I added it to the files array of |
Getting this error every time although it works and shows lint errors.
Log:
Also had to add
"no-unused-variable": false,
to tslint for"allowUnused": false
to work properly.The text was updated successfully, but these errors were encountered: