This app is intended to show a simple chat functionality using Socket.io in addition with Ruby on Rails and Angular2.
The structure of the project is very simple:
- client-side: front-end side build in angular which allows users to interact with the application. Also communicate with socket-io-server to listen for incomming messages. All the information is send and request via a Rails API.
- socket-io-server: listen and broadcast messages from Redis, a in-memory database which storage keys with an optional durability.
- rails-api-server: back-end side build in rails which send and request data via an API. It communicates with Redis to storage new messages.
Because Rails is not an event-based server is not recommended to use it having real time applications. That's why Redis is so important, give you the communication between your data and the socket-io-server. This article explain with more details.
Make sure you have all the components up and running. Please go to the readme pages in every case.
https://gmunumel-chat-client-side.herokuapp.com/
Licensed under MIT