How to debug jade object printing

How to debug object printing from jade, Like console.log() in javascript

+5
source share
3 answers

You can debug with console.log from jade as follows:

 div - console.log(the_object_you_want_to_log) div 
+5
source

It helps me! The ability to see the entire object tree in the console.

Run the script. from the left and just give a space or tab according to your template before console.log.

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

You can debug this

 div = your_debug_data div 

or formatted style, for example:

 code.formattedDebug #{your_debug_data} 
0
source

All Articles