How to debug print an object from jade

萝らか妹 提交于 2019-12-05 04:33:43

You can debug with console.log from jade like this:

div
- console.log(the_object_you_want_to_log)
div

This helped me! Able to see whole tree of Object in console.

Start script. from leftmost and just give space or tab according to your template before console.log.

script.
  console.log(!{JSON.stringify(Object)})

You can debug like this

div
   = your_debug_data
div

or formatted style like:

code.formattedDebug #{your_debug_data}
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!