Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mfrachet/server-push-hooks
🔥 React hooks for Socket.io, SSE, WebSockets and more to come
https://github.com/mfrachet/server-push-hooks
hooks react server-sent-events socketio sse
Last synced: about 18 hours ago
JSON representation
🔥 React hooks for Socket.io, SSE, WebSockets and more to come
- Host: GitHub
- URL: https://github.com/mfrachet/server-push-hooks
- Owner: mfrachet
- License: mit
- Created: 2018-11-13T16:20:34.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2023-11-14T07:21:16.000Z (about 1 year ago)
- Last Synced: 2025-01-05T00:15:58.963Z (8 days ago)
- Topics: hooks, react, server-sent-events, socketio, sse
- Language: JavaScript
- Homepage: https://codesandbox.io/s/y091y50plz
- Size: 1.89 MB
- Stars: 197
- Watchers: 6
- Forks: 26
- Open Issues: 24
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
- fucking-awesome-react-hooks - `server-push-hooks` - US/docs/Web/API/Server-sent_events/Using_server-sent_events) and more to come (Packages)
- awesome-react-hooks-cn - `server-push-hooks` - US/docs/Web/API/Server-sent_events/Using_server-sent_events) and more to come (Packages)
- awesome-react-hooks - `server-push-hooks` - US/docs/Web/API/Server-sent_events/Using_server-sent_events) and more to come (Packages)
- awesome-react-hooks - `server-push-hooks` - US/docs/Web/API/Server-sent_events/Using_server-sent_events) and more to come (Packages)
README
[![Build Status](https://travis-ci.org/mfrachet/use-socketio.svg?branch=master)](https://travis-ci.org/mfrachet/use-socketio)
React hooks for handling server-push technologies:
- [use-socketio](./packages/use-socketio) for [Socket.io](https://socket.io/)
- [use-server-sent-events](./packages/use-server-sent-events) for [Server Sent Events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events)
- [use-websockets](./packages/use-websockets) for [Websocket](https://developer.mozilla.org/en-US/docs/Web/API/WebSockets_API)## Running samples
To run samples locally, you can:
```sh
$ git clone https://github.com/mfrachet/server-push-hooks
$ cd server-push-hooks
$ npm install # install lerna and dependencies at the root
$ npm run bootstrap # install lerna packages dependencies
$ npm run build # build the lerna packages
$ npm start # start the web application
$ npm start:test-server # start the backend services in another terminal
$ npm run e2e # run E2E tests of the projects in another terminal
```