2017-03-11 7 views
0

私はangular2をサポートするjava webappを持っています。角度のない簡単な構成で、テストとngの提供なし

.javaと.tsファイルのパッケージ化とコンパイルはmavenで行われ、次にspring-bootを使用してコードのホットデプロイメントを実行して.warを実行します。

私はangular-cliをコンポーネント、サービスなどを生成するために同意するまで使用したいと思います。私はまだジャスミンテストを追加する予定はないので、テストやサーバー設定などは心配していません。 Webpackingと追加のangular-cliガベージファイルのいずれかを必要としません。 package.json で定義されているものだけですファイル構造を生成するために既存のプロジェクトでangular-cliを使用できる方法はありますか?

以下は、プロジェクトとファイルの構造です。次

src/main/webapp 
src/main/webapp/package.json 
src/main/webapp/systemjs.config.js 
src/main/webapp/app 
src/main/webapp/main.ts 
src/main/webapp/module.ts 
src/main/webapp/component.ts 
src/main/webapp/landing.html 
src/main/webapp/node_modules 

は、私はこれがあなたの質問に答えるかはわからないが、あなたは最小限のアプリを作成するには、このコマンドラインを使用して任意のテストをせずにすることができます私のpackage.json

{ 
    "name": "angular-simple-start", 
    "version": "1.0.0", 
    "description": "Simple app", 
    "scripts": { 
    }, 
    "dependencies": { 
    "@angular/common": "~2.4.0", 
    "@angular/compiler": "~2.4.0", 
    "@angular/core": "~2.4.0", 
    "@angular/forms": "~2.4.0", 
    "@angular/http": "~2.4.0", 
    "@angular/platform-browser": "~2.4.0", 
    "@angular/platform-browser-dynamic": "~2.4.0", 
    "@angular/router": "~3.4.0", 

    "angular-in-memory-web-api": "~0.2.4", 
    "systemjs": "0.19.40", 
    "core-js": "^2.4.1", 
    "rxjs": "5.0.1", 
    "zone.js": "^0.7.4" 
    }, 
    "devDependencies": { 
    "concurrently": "^3.2.0", 
    "typescript": "~2.0.10", 
    "@types/node": "^6.0.46", 
    }, 

} 

答えて

4

です:

ng new --skip-test --minimal <project_name> 
関連する問題