Introduction to Angular 2 with Spring MVC

Monday, 9:00 AM - SALON 2

Do you work in a Java shop and want to get started with Angular 2? If so, this workshop is for you. An essential component of starting with Angular 2 is learning the build tools. It presents a major shift from how we integrated our JavaScript in the past. There isn't an established convention for integrating with Java Web Applications. In this workshop, we will cover the fundamentals of Angular 2 including: typescript, components, templates, dependency injection, routing, services, http, and observables. In addition, we'll integrate an Angular app in a Spring MVC app and establish a productive workflow.

This workshop will start with the fundamentals of Angular and then create an App within an existing SpringMVC app. Knowledge of Spring MVC is helpful, but not necessarily required. We'll primarily focus on the build and deployment aspects of Spring MVC. This workshop will use the following tools: angular-cli, npm, git, gradle, and gulp.

Workshop Requirements

This session is a workshop. Please come prepared.

1) Install Recent Node - v6.5.0 or Higher

OS X: https://nodejs.org/dist/v6.5.0/node-v6.5.0.pkg
Windows: https://nodejs.org/dist/v6.5.0/win-x64/node.exe
Linux: https://nodejs.org/dist/v6.5.0/node-v6.5.0-linux-x64.tar.xz
Other: https://nodejs.org/en/

2) Install Angular CLI, Gulp, and TypeScript

npm install -g angular-cli gulp typescript

If you need uninstall an older angular-cli version:

    npm uninstall -g angular-cli 
    npm cache clear

3) Install Java 8

http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html

Make sure the Java 8 JDK is your default java version on the system.

java -version
java version "1.8.0_101"

Check your JAVA_HOME environment variable. Make sure it is set to the Java 8 JDK.

4) Clone Workshop Repo

git clone git@github.com:bellingson/ng-workshop-starter.git

5) Install npm dependencies

cd ng-workshop-starter/product-mgr
npm install

cd ng-workshop-starter/stuffmart
npm install

6) Test Angular CLI Installation

ng -v

should print angular-cli: 1.0.0-beta.20-4 (or higher)

cd ng-workshop-starter/product-mgr
ng serve

got to http://localhost:4200/ in browser
should say "app works!"

7) Test Spring MVC App

On mac and linux:

cd ng-workshop-starter/stuffmart
./gradlew appRun

On windows:

경축! 아무것도 안하여 에스천사게임즈가 새로운 모습으로 재오픈 하였습니다.
어린이용이며, 설치가 필요없는 브라우저 게임입니다.
https://s1004games.com

cd ng-workshop-starter/stuffmart
./gradlew.bat appRun

go to http://localhost:8080/ in browser
should load "Stuff Mart" website

Browser

Chrome Browser is prefered

IDE Recommendations

IntelliJ Ultimate and Visual Studio Code seem to have the best Angular 2 support at this time. Both offer code completion and automatic imports. The workshop instructor will use IntelliJ Ultimate, but you are free to use another IDE that you are comfortable with.

  • IntelliJ Ultimate Edition (not free)

    https://www.jetbrains.com/idea/#chooseYourEdition

    Also install Angular JS plugin
    https://plugins.jetbrains.com/plugin/6971?pr=phpStorm

  • IntelliJ Community Edition (free) is good too, but lacks JavaScript code completion

  • Visual Studio Code

    https://code.visualstudio.com/

Also recommend installing an Emmet plugin for any IDE you use.

http://emmet.io/

About Ben Ellingson

Ben Ellingson

Ben is a full-stack web developer, mobile app developer, and designer. He is the developer behind nofluffjuststuff.com, uberconf.com, angularsummit.com, several other NFJS websites, and NFJS mobile apps (iOS and Android). He is fluent in JavaScript, Angular, Groovy, Java, Objective-C, Swift, and Front-end engineering. He has 19 years of development experience and is constantly learning new technologies.

 

[출처] https://angularsummit.com/conference/boston/2016/09/session?id=36767

 

 

 

 

본 웹사이트는 광고를 포함하고 있습니다.
광고 클릭에서 발생하는 수익금은 모두 웹사이트 서버의 유지 및 관리, 그리고 기술 콘텐츠 향상을 위해 쓰여집니다.
번호 제목 글쓴이 날짜 조회 수
26 [bootstrap] spring 프로젝트에 bootstrap 적용 file 졸리운_곰 2017.01.29 164
25 eGov 표준프레임워크(전자정부프레임워크) 공통 컴포넌트 사용법 : Common Component file 졸리운_곰 2017.01.29 1030
24 Passing Javascript object and object list to Spring controller 졸리운_곰 2017.01.23 92
23 뷰에 모델(Model) 전달 file 졸리운_곰 2017.01.22 128
22 CentOS에서 Apache Tomcat 설치하기 졸리운_곰 2017.01.18 490
21 Spring MVC Tiles Plugin with Example file 졸리운_곰 2017.01.15 1384
20 Spring MVC Tiles 3 Integration Tutorial file 졸리운_곰 2017.01.15 173
19 Spring 3 MVC: Tiles Plugin Tutorial with Example in Eclipse file 졸리운_곰 2017.01.15 194
18 MyBatis 에서 한 insert 태그로 여러 Insert문 수행 졸리운_곰 2016.12.09 112
17 Web App Architecture - the Spring MVC - AngularJs stack file 졸리운_곰 2016.11.20 208
» Introduction to Angular 2 with Spring MVC file 졸리운_곰 2016.11.20 676
15 Migrating a Spring Web MVC application from JSP to AngularJS file 졸리운_곰 2016.11.20 114
14 스프링(Spring) MVC 프레임워크(Model View Controller Framework) file 졸리운_곰 2016.11.16 151
13 JSP 정리 졸리운_곰 2016.09.11 332
12 JSP 요약 정리 file 졸리운_곰 2016.09.11 1294
11 전자정부 eGov 프레임워크 모바일 실행환경 Upgrade 가이드 file 졸리운_곰 2016.08.02 327
10 전자정부 eGov 프레임워크 개발프레임워크 개발환경 졸리운_곰 2016.08.02 474
9 표준프레임워크 실행환경 3.5 졸리운_곰 2016.08.02 172
8 전자정부 표준프레임워크 3.5 기반 개발 시작하기(Getting Started) file 졸리운_곰 2016.08.02 291
7 스프링(Spring) MVC 프레임워크(Model View Controller Framework) file 졸리운_곰 2016.07.31 103
대표 김성준 주소 : 경기 용인 분당수지 U타워 등록번호 : 142-07-27414
통신판매업 신고 : 제2012-용인수지-0185호 출판업 신고 : 수지구청 제 123호 개인정보보호최고책임자 : 김성준 sjkim70@stechstar.com
대표전화 : 010-4589-2193 [fax] 02-6280-1294 COPYRIGHT(C) stechstar.com ALL RIGHTS RESERVED