https://github.com/mat-sz/poll-web
🗳️ Decision making software frontend (TypeScript/React/WebSockets).
https://github.com/mat-sz/poll-web
react reactjs typescript websocket
Last synced: about 2 months ago
JSON representation
🗳️ Decision making software frontend (TypeScript/React/WebSockets).
- Host: GitHub
- URL: https://github.com/mat-sz/poll-web
- Owner: mat-sz
- License: bsd-3-clause-clear
- Created: 2020-05-09T16:43:40.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2020-07-01T16:04:33.000Z (almost 6 years ago)
- Last Synced: 2025-06-12T03:49:35.801Z (about 1 year ago)
- Topics: react, reactjs, typescript, websocket
- Language: TypeScript
- Size: 463 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# poll-web
Easy to use, self-hosted polling web application a React.js web interface. Fully written in TypeScript.
## Self-hosting
> First you need to clone, build and run [poll-ws](https://github.com/mat-sz/poll-ws), read the README in poll-ws for more information on configuration.
>
> Then you need to clone this project, point it to the WebSockets backend (poll-ws) (in .env.local), build it and place it on some static file server (I use nginx for that). I also use nginx to proxy the back end through it. [Here's a guide on how to achieve that.](https://www.nginx.com/blog/websocket-nginx/)
### Environment variables
The following variables are used in the build process:
| Variable | Default value | Description |
| ------------------------------ | ------------------------- | --------------------------------------------------------------------------- |
| `REACT_APP_TITLE` | `poll` | Application title. |
| `REACT_APP_SERVER_WS` | `ws://[hostname]:5000/ws` | WebSockets server location. |
| `REACT_APP_SERVER_API` | `http://[hostname]:5000/` | HTTP API server location. |
| `REACT_APP_USE_BROWSER_ROUTER` | `0` | `1` if you want the application to use BrowserRouter instead of HashRouter. |