We define then a new function handle_msg/2 .def handle_frame({:text, msg}, state) do handle_msg(Poison.decode!(msg), state)enddef handle_msg(%{"type" => "match"}=trade, state) do IO.inspect(trade) {:ok,…
Continue ReadingWe define then a new function handle_msg/2 .def handle_frame({:text, msg}, state) do handle_msg(Poison.decode!(msg), state)enddef handle_msg(%{"type" => "match"}=trade, state) do IO.inspect(trade) {:ok,…
Continue Reading