Jade with Express - how to disable ReferenceError

i want replace empty string instead of ReferenceError. following code :

p #{data.data.data}

ReferenceError occured when render template that i want disable it.

Stumbled onto the same thing, but passing an empty object felt wrong. I suggest handling the possibility in the template with something like:

- if(data)
  p #{data.data.data}
- else
  p No data for you!

Or specify a placeholder inline

p #{data.data.data ? data.data.data : 'No data'}

Pass an empty object if there is no value when rendering:

res.render('view/index', {data: your_data_variable || {} });