ng --version. angular-cli: 1.0.0-beta.1
node: 4.2.6
os: win32 x64
Steps
project.component.spec.ts and then project.component.tsObserve that you get errors about unsupported decorators in the second file. The reason is that the generated tsconfig.json file has a files sections only including main.ts and typings.d.ts. Either the files section must list all src files or better be removed to cover all *.ts files automatically. Otherwise the files under src will not honor the tsconfig.json settings.
Generated output causes issues in IntelliJ IDEA as well:
files section it warns that it won't compile .ts files, as they are not listed in tsconfig.jsonfiles section IDEA is happy, but basic tasks like ng server or ng test fail with cryptic stacktraces containing a _"Cannot find name 'module'."_ as hint.A workaround is to choose "set options manually" and transform the configuration of tsconfig.json into tsc arguments.
For me the following arguments seem to do the trick:
--experimentalDecorators --emitDecoratorMetadata --mapRoot "/" -m "commonjs" --moduleResolution "node" --noEmitOnError --outDir "../dist/" --rootDir "$ModuleFileDir$/src" --sourceMap -t "es5" --inlineSources
I have created ts configuration files that work in VS Code and Broccoli. I posted them here: https://github.com/Microsoft/vscode/issues/8954#issuecomment-231960894.
It appears the two sets of settings are mutually exclusive. If I apply the VS Code Settings, Broccoli breaks. If I apply the Broccoli Settings, VS Code throws errors.
I can post more of my project if that will help. I can also give an individual access to our BitBucket repo.
I see a solution here for IntelliJ IDEA.
I'm not sure how I'm supposed to configure VS Code so the Editor and Broccoli are both happy.
Maybe I'm too thick to see the solution?
I tried looking at Broccoli for help. I have no idea where to start. They have hundreds of projects. Sorry to be such a newb.
Based on my conversations with Microsoft, the files attribute is a violation of the current standard for TS. This is the same issue that IDEA is having. It will also not work out of the box.
How would I raise this as an issue with Broccoli?
Does Broccoli have a newer compiler to which we can upgrade which is standards compliant?
Exactly which TS compiler is being used?
I have looked at broccoli-typescript.js and it looks like you are using that setting to filter the *.d.ts files that are used by the incremental compile. I commented out lines 59-61. That made me clean up the typings directory. However, I still have two problems:
Fixed by #1455.
This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
_This action has been performed automatically by a bot._
Most helpful comment
Fixed by #1455.