© Christopher Pitt and Joe Mancuso 2020
C. Pitt, J. MancusoThe Definitive Guide to Masonitehttps://doi.org/10.1007/978-1-4842-5602-2_11

11. Adding Websockets with Pusher

Christopher Pitt1  and Joe Mancuso2
(1)
Cape Town, South Africa
(2)
Holbrook, NY, USA
 

We’ve done a lot of server-side work, but now it’s time to do some work in the browser. Specifically, I want us to look at how we can “push” new information to the browser, without the user initiating the action (by clicking a button or typing a message).

“Isn’t That Ajax?”

When we looked at creating forms, in Chapter 5, we spoke about Ajax and Websockets. To recap, Ajax is a method for sending requests to the server, without loading a new URL in the browser, and updating small parts of the page when ...

Get The Definitive Guide to Masonite: Building Web Applications with Python now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.