Welcome toVigges Developer Community-Open, Learning,Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.2k views
in Technique[技术] by (71.8m points)

spring - Can we use angular2 universal with server side JAVA

I have an web project which is using angular 2 on front end and java spring 4 on server side. I am somewhat new to angular 2. I wanted to use angular universal for prerendering. How can i able to achieve it?

is there any tutorial which explains it with Java on server side?

Is there any other library that will help me out?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Fortunately their's a library (Angularj-Universal) or a solution for rendering Angular4 applications on the server side (Spring Boot or Java EE) and sending them to the browser as 'already-bootstraped' application.

Angularj-Universal library is a server side rendering for Spring Boot and Angular4 based on the J2V8 library, also you can implement your own render implementation.

On the home page of this project you will find a useful guides step-by-step on how to create angular application from scratch and integrate it with Spring Boot using @angular/cli


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to Vigges Developer Community for programmer and developer-Open, Learning and Share
...