If available in Hex, the package can be installed as:
- Add simple_tcp to a list of dependencies in
mix.exs
:
[{:simple_tcp, git: "https://github.com/VladimirMikhailov/elixir_simple_tcp.git"}
- Ensure simple_tcp is started:
def application do
[
extra_applications: [:logger, :simple_tcp]
]
end
-
Run
iex -S mix
-
Connect by telnet client:
telnet localhost 8000
Channels and the app don't store any information and messages get spread only to connected clients.
/c NEW ROOM
- Connect to a channel