therewillbecode / poker-maison

🂺 A Multiplayer Poker App Crafted with Haskell and React
309 stars 34 forks source link

Use Servant-Pipes for streaming endpoints #9

Open therewillbecode opened 4 years ago

therewillbecode commented 4 years ago

Right now there are two separate APIs the socket server for game logic and the Servant API for authentication logic.

Servant-pipes library should be used so that we can remove the socket server all together and just create a streaming endpoint in the Servant API.

An example can be seen here.

https://github.com/haskell-servant/servant/blob/master/servant-pipes/example/Main.hs