ConaGo / learn-scala-play

learning scala with the play framework

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Play Hello World Web Tutorial for Scala

To follow the steps in this tutorial, you will need the correct version of Java and sbt. The template requires:

  • Java Software Developer's Kit (SE) 1.8 or higher
  • sbt 1.3.4 or higher. Note: if you downloaded this project as a zip file from https://developer.lightbend.com, the file includes an sbt distribution for your convenience.

To check your Java version, enter the following in a command window:

java -version

To check your sbt version, enter the following in a command window:

sbt sbtVersion

If you do not have the required versions, follow these links to obtain them:

Build and run the project

This example Play project was created from a seed template. It includes all Play components and an Akka HTTP server. The project is also configured with filters for Cross-Site Request Forgery (CSRF) protection and security headers.

To build and run the project:

  1. Use a command window to change into the example project directory, for example: cd play-scala-hello-world-web

  2. Build the project. Enter: sbt run. The project builds and starts the embedded HTTP server. Since this downloads libraries and dependencies, the amount of time required depends partly on your connection's speed.

  3. After the message Server started, ... displays, enter the following URL in a browser: http://localhost:9000

The Play application responds: Welcome to the Hello World Tutorial!

About

learning scala with the play framework

License:Creative Commons Zero v1.0 Universal


Languages

Language:HTML 51.5%Language:CSS 43.5%Language:Scala 4.4%Language:Shell 0.5%Language:Batchfile 0.1%