O'Reilly logo

Play for Scala by Peter Hilton, Erik Bakker

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 8. Building a single-page JavaScript application with JSON

This chapter covers

  • Defining a RESTful web service
  • Sending JSON to the web browser
  • Parsing JSON from an HTTP request
  • Converting between JSON data and Scala objects
  • Validating JSON data
  • Authenticating JSON web service requests

In this chapter, we’re going to reimplement part of the sample application from chapter 2 using a more modern JavaScript client application architecture that allows you to make more responsive web applications with richer and more interactive user interfaces.

We’re going to use Play to build the server for a JavaScript application that runs in the browser. Instead of using view templates to generate HTML on the server and send web pages to the browser, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required