https://github.com/miguelgrinberg/socketio-examples
A few examples that demonstrate the features of the Python Socket.IO server
https://github.com/miguelgrinberg/socketio-examples
flask socket-io websocket
Last synced: about 2 months ago
JSON representation
A few examples that demonstrate the features of the Python Socket.IO server
- Host: GitHub
- URL: https://github.com/miguelgrinberg/socketio-examples
- Owner: miguelgrinberg
- License: mit
- Created: 2017-10-08T17:26:15.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2017-10-08T18:30:58.000Z (about 8 years ago)
- Last Synced: 2025-07-01T14:07:01.427Z (4 months ago)
- Topics: flask, socket-io, websocket
- Language: JavaScript
- Size: 33.2 KB
- Stars: 92
- Watchers: 3
- Forks: 36
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Socket.IO Examples
This repository contains a few examples that demonstrate the features of the
Python Socket.IO server in combination with Flask.
## How to Run
First create a virtual environment and import the requirements.
One of the demos uses the Google Maps API. For that demo to work you need to
request a Google Maps API key from Google, as described
[here](https://developers.google.com/maps/documentation/javascript/get-api-key).
To start the server, run:
```
(venv) $ export GOOGLE_MAPS_KEY=
(venv) $ export FLASK_APP=socketio_examples.py
(venv) $ flask run
```
Finally, open _http://localhost:5000_ on your web browser to access the
application.
Note: You can run the application without a Google Maps key. All the demos
except "Where do you live?" will work just fine.