Skip to Content
Building Scalable Apps with Redis and Node.js
book

Building Scalable Apps with Redis and Node.js

by Joshua Johanan
September 2014
Intermediate to advanced
316 pages
7h 6m
English
Packt Publishing
Content preview from Building Scalable Apps with Redis and Node.js

Inspecting requests

HTTP is request based. The browser makes a request and our web server responds with a response. This interaction is hidden from users in all browsers, for a good reason. When developing applications, we will have the need to view this interaction. For this we will use Chrome's Network tab.

This will be our first new application, so create a directory named requests. This directory will be the root of our project. The first thing we will do is use a basic Express server. This code is right from Express' API documentation. It is the most basic functioning 'hello world' we can build. Create an app.js file and add the following code to it:

var express = require('express'); var app = express(); app.get('/', function(req, res){ res.send('hello ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Reactive Programming with Node.js

Reactive Programming with Node.js

Fernando Doglio
Node: Up and Running

Node: Up and Running

Tom Hughes-Croucher, Mike Wilson
Learn TypeScript 3 by Building Web Applications

Learn TypeScript 3 by Building Web Applications

Sebastien Dubois, Alexis Georges

Publisher Resources

ISBN: 9781783984480Supplemental Content