GithubHelp home page GithubHelp logo

legendpeng / play-scala-starter-example Goto Github PK

View Code? Open in Web Editor NEW

This project forked from playframework/play-scala-starter-example

0.0 1.0 0.0 61 KB

Play Scala Starter Template (ideal for new users!)

Home Page: https://playframework.com/documentation/latest/ScalaHome

License: Other

Scala 32.16% HTML 25.60% JavaScript 0.27% CSS 41.97%

play-scala-starter-example's Introduction

play-scala-starter-example

This is a starter application that shows how Play works. Please see the documentation at https://www.playframework.com/documentation/latest/Home for more details.

Running

Run this using sbt. If you downloaded this project from http://www.playframework.com/download then you'll find a prepackaged version of sbt in the project directory:

sbt run

And then go to http://localhost:9000 to see the running web application.

There are several demonstration files available in this template.

Controllers

  • HomeController.scala:

    Shows how to handle simple HTTP requests.

  • AsyncController.scala:

    Shows how to do asynchronous programming when handling a request.

  • CountController.scala:

    Shows how to inject a component into a controller and use the component when handling requests.

Components

  • Module.scala:

    Shows how to use Guice to bind all the components needed by your application.

  • Counter.scala:

    An example of a component that contains state, in this case a simple counter.

  • ApplicationTimer.scala:

    An example of a component that starts when the application starts and stops when the application stops.

Filters

  • Filters.scala:

    Creates the list of HTTP filters used by your application.

  • ExampleFilter.scala

    A simple filter that adds a header to every response.

play-scala-starter-example's People

Contributors

gmethvin avatar marcospereira avatar richdougherty avatar wsargent avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.