2016-07-17 44 views
0

私のサーバー.tsモジュールはモジュールをインストールしていないと文句を言っていますが、モジュールをインストールしてnode_modulesをチェックしました。Typescriptがモジュールを見つけることができません

これは私のプロジェクト構造である:私が得るscreenshot

エラー:screenshot

tsconfig.json

{ 
    "compilerOptions": { 
     "module": "commonjs", 
     "moduleResolution": "node", 
     "target": "es5", 
     "sourceMap": true, 
     "emitDecoratorMetadata": true, 
     "experimentalDecorators": true, 
     "noImplicitAny": false 
    }, 
    "exclude": [ 
     "node_modules", 
    "typings" 
    ], 
    "filesGlob": [ 
    "**/*.ts", 
    "typings/main", 
    "./typings/index.d.ts" 
    ] 
} 
+0

あなたは 'tscg'を使ってコードをコンパイルしていますか? –

+0

いいえ.............................. –

+0

https://www.npmjs.com/package/typescript-with-グロブス –

答えて

0
filesGlobがまだネイティブtypescriptですではサポートされていません

github

私の提案はfilesGlobセクションをそのまま削除することです

{ 
    "compilerOptions": { 
     "module": "commonjs", 
     "moduleResolution": "node", 
     "target": "es5", 
     "sourceMap": true, 
     "emitDecoratorMetadata": true, 
     "experimentalDecorators": true, 
     "noImplicitAny": false 
    }, 
    "exclude": [ 
     "node_modules", 
     "typings/browser.d.ts", 
     "typings/browser/**" 
    ] 
} 

希望が実際に必要なように見えます。

関連する問題