Template.save in html file is possibile?

Hi all,
I’m trying to save a template in html format I created using the panel library in jupyterlab:

template.save(‘dashboard.html’)

however i encounter this error:

UndefinedError: ‘template_resources’ is undefined

P.S.: the template is showing correctly using .show()