Formatted text, code block in draw.io

draw.iotext formatting

I want to add JSON code snippets to my diagram in draw.io. When I use copy/paste to a text box, the indented spaces/tabs get lost.

Does anyone know how to copy formatted snippets from notepad++/VS Code to draw.io?

Best Answer

Try to convert tabs into spaces in Notepad++. It should do the trick.

If you don't know how consult this question on Stackoverflow.