Ch 5 Configuring an injector: TSError: Unable to compile TypeScript
mattqs opened this issue · 2 comments
mattqs commented
On Ubuntu 14.04:
apollo@atomix> node --version
v5.10.1
apollo@atomix> npm --version
3.8.6
apollo@atomix> uname -a
Linux atomix 3.19.0-39-generic #44~14.04.1-Ubuntu SMP Wed Dec 2 10:00:35 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
apollo@atomix>
I follow instructions at location 2434 in kindle book.
apollo@atomix> ts-node ch5/ts/injector-basics/injector.ts
TSError: ⨯ Unable to compile TypeScript
ch6/ts/step-1-async/app.ts (24,7): Cannot find name 'System'. (2304)
ch6/ts/step-1-async/app.ts (31,7): Cannot find name 'System'. (2304)
ch8/ts/todo_webworkers/loader.ts (5,1): Cannot find name 'System'. (2304)
ch8/ts/todo_webworkers/loader.ts (9,1): Cannot find name 'System'. (2304)
at getOutput (/usr/local/lib/node_modules/ts-node/src/ts-node.ts:210:13)
at Object.loader (/usr/local/lib/node_modules/ts-node/src/ts-node.ts:225:23)
at Module.load (module.js:357:32)
at Function.Module._load (module.js:314:12)
at Function.Module.runMain (module.js:447:10)
at Object.<anonymous> (/usr/local/lib/node_modules/ts-node/src/bin/ts-node.ts:110:12)
at Module._compile (module.js:413:34)
at Object.Module._extensions..js (module.js:422:10)
at Module.load (module.js:357:32)
at Function.Module._load (module.js:314:12)
It looks like it is trying to compile ch6 code, so I tried -n
flag:
apollo@atomix> ts-node -n ./ch5/ts/injector-basics/injector.ts
TSError: ⨯ Unable to compile TypeScript
ch5/ts/injector-basics/injector.ts (13,15): Experimental support for decorators is a feature that is subject to change in a future release. Set the 'experimentalDecorators' option to remove this warning. (1219)
ch5/ts/injector-basics/injector.ts (19,7): Experimental support for decorators is a feature that is subject to change in a future release. Set the 'experimentalDecorators' option to remove this warning. (1219)
../node_modules/angular2/src/core/application_ref.d.ts (83,60): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/application_ref.d.ts (83,146): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/application_ref.d.ts (96,51): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/application_ref.d.ts (96,147): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/application_ref.d.ts (133,90): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/application_ref.d.ts (171,81): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/change_detection/differs/default_keyvalue_differ.d.ts (23,15): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/core/change_detection/differs/default_keyvalue_differ.d.ts (25,16): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/core/change_detection/parser/locals.d.ts (3,14): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/core/change_detection/parser/locals.d.ts (4,42): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/core/debug/debug_node.d.ts (14,13): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/core/debug/debug_node.d.ts (24,17): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/core/debug/debug_node.d.ts (25,17): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/core/di/provider.d.ts (436,103): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/core/di/provider.d.ts (436,135): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/core/linker/compiler.d.ts (12,50): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/linker/compiler.d.ts (16,41): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/linker/dynamic_component_loader.d.ts (108,136): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/linker/dynamic_component_loader.d.ts (156,150): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/linker/dynamic_component_loader.d.ts (197,128): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/linker/dynamic_component_loader.d.ts (203,127): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/linker/dynamic_component_loader.d.ts (204,141): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/linker/dynamic_component_loader.d.ts (205,119): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/core/render/api.d.ts (13,13): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/core/render/api.d.ts (14,84): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/facade/async.d.ts (27,33): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/facade/async.d.ts (28,45): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (1,25): Cannot find name 'MapConstructor'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (2,25): Cannot find name 'SetConstructor'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (4,27): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (4,39): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (7,9): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (8,30): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (11,43): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (12,27): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (14,23): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (15,25): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (97,41): Cannot find name 'Set'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (98,22): Cannot find name 'Set'. (2304)
../node_modules/angular2/src/facade/collection.d.ts (99,25): Cannot find name 'Set'. (2304)
../node_modules/angular2/src/facade/lang.d.ts (13,17): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/facade/lang.d.ts (14,17): Cannot find name 'Set'. (2304)
../node_modules/angular2/src/facade/lang.d.ts (79,59): Cannot find name 'Map'. (2304)
../node_modules/angular2/src/facade/promise.d.ts (2,14): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/facade/promise.d.ts (7,32): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/facade/promise.d.ts (8,38): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/facade/promise.d.ts (9,35): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/facade/promise.d.ts (9,93): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/facade/promise.d.ts (10,34): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/facade/promise.d.ts (11,32): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/facade/promise.d.ts (11,149): Cannot find name 'Promise'. (2304)
../node_modules/angular2/src/facade/promise.d.ts (12,43): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/CoreOperators.d.ts (35,67): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/CoreOperators.d.ts (50,66): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/CoreOperators.d.ts (89,67): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/CoreOperators.d.ts (94,38): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/CoreOperators.d.ts (94,50): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/Observable.d.ts (46,62): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/Observable.d.ts (47,42): Cannot find name 'Iterator'. (2304)
../node_modules/rxjs/Observable.d.ts (103,74): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/Observable.d.ts (103,84): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/Observable.d.ts (143,66): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/Observable.d.ts (158,65): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/Observable.d.ts (201,66): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/Observable.d.ts (206,38): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/Observable.d.ts (206,50): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/observable/ForkJoinObservable.d.ts (6,50): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/observable/ForkJoinObservable.d.ts (7,58): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/observable/FromObservable.d.ts (7,38): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/observable/FromObservable.d.ts (7,51): Cannot find name 'Iterator'. (2304)
../node_modules/rxjs/observable/PromiseObservable.d.ts (9,31): Cannot find name 'Promise'. (2304)
../node_modules/rxjs/observable/PromiseObservable.d.ts (10,26): Cannot find name 'Promise'. (2304)
at getOutput (/usr/local/lib/node_modules/ts-node/src/ts-node.ts:210:13)
at Object.loader (/usr/local/lib/node_modules/ts-node/src/ts-node.ts:225:23)
at Module.load (module.js:357:32)
at Function.Module._load (module.js:314:12)
at Function.Module.runMain (module.js:447:10)
at Object.<anonymous> (/usr/local/lib/node_modules/ts-node/src/bin/ts-node.ts:110:12)
at Module._compile (module.js:413:34)
at Object.Module._extensions..js (module.js:422:10)
at Module.load (module.js:357:32)
at Function.Module._load (module.js:314:12)
mgechev commented
Thanks, I'll take a look today or tomorrow.
mgechev commented
Should be good now.