How to Log something in Controller when Phoenix Server is running?

前端 未结 2 1571
陌清茗
陌清茗 2021-02-01 00:35

I\'m trying to print some debug information from one of my Controllers in my Phoenix app when the server is running.

defmo         


        
2条回答
  •  清酒与你
    2021-02-01 00:57

    You can also just do IO.puts or IO.inspect and it'll show up, but IO.puts can be troublesome if what you're trying to print doesn't implement the String.Chars protocol

提交回复
热议问题