-
Notifications
You must be signed in to change notification settings - Fork 12k
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 on file "is missing from the TypeScript compilation" when invoking ng build or ng serve #9523
Comments
I believe this issue can now be closed. There was indeed a typo in one of the TS imports but not on any of the files that the error was indicating but on another ts model file that was referencing the person.ts. I was able to found this after trying to clone the project into a different machine and compiling it. Curious enough is that, despite having build errors and being the same project, the messages between the two machines were quite different. |
To add my experience, I had an error like this but it ended up being an issue of case sensitivity. On my machine, it showed a folder as As a result, one of the .ts files showed up on the build server as not being included in Typescript compilation but on all other machines that I tested it on, it worked just fine. Apparently my git config settings were set to ignore case. I spent 6 hours debugging this issue, so hopefully I can save a few people some time. |
I have this issue....this issue sucks :( this is how I solved it for local development: https://stackoverflow.com/questions/48797135/missing-ts-files-due-to-npm-link/48798373#48798373 |
It was same to me... I could figured it out when I executed |
It was also an issue with an import written has |
@cedvdb, Thanks, it fixed my problem. |
It was also an issue with an import written has ./Store instead of ./store
|
I am facing this issue when I am using environment specific providers. |
@ORESoftware Thank you so much for the solution. I have fixed the issues. Follow link help me to fix : https://stackoverflow.com/questions/48797135/missing-ts-files-due-to-npm-link/48798373#48798373 |
@lusocoding, |
I'm not sure. It was a long time ago. But I think it was a case sensitive issue. |
Just for some helpful input, if you create a symlink on windows (mklink /D) and try to compile from the path that link points to, you also see this issue. |
For all with the symlink problem, this helps: https://github.com/angular/angular-cli/issues/10735#issuecomment-387636803 |
Incorrect link location but if you use the text's location, it works - and it solved my problem (multiple apps in ng projects where I used symlink). So, text is the real link. |
Just in case anyone jumped the gun like me... I had simply altered the file structure and forgotten to stop/start |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
I have the following folder/file structure on a sample angular5 application created using angular-cli:
When trying to do a "ng build" or "ng serve" I'm getting the below error:
Already found a bunch of articles suggesting to do "ng serve --preserve-symlinks" or to modify the "tsconfig.json" and/or "tsconfig.app.json" to include all the .ts files found under src/app folder. None of the approaches I found on my research seems to work.
Also made sure I don't have a typo and I'm sure that is not the problem right now.
BTW, the index.ts files under "model" and "services" are just exporting all the classes under those folders, such as:
Any ideas of other approaches that I can test to see if I can compile the application correctly?
Versions used:
The text was updated successfully, but these errors were encountered: