How to download multiple diagram in PDF format without using external libraries and without switching the diagram model?

I need to download multiple diagram images in PDF format, but I only have a single diagram container (div). The diagrams are displayed one at a time based on selected data. However, I want to download all diagrams as a single PDF. I cannot use libraries such as SvgToPDF or PDFKit.

When I try to retrieve the diagram data using ‘fromDiv’, the last diagram model data is always assigned to the selected diagram. How can I resolve this issue?

The GoJS library does not have built-in support for rendering PDF files. Why can you not use a PDF JavaScript library when building a PDF file?

I assume you have seen our three PDF downloading samples in the samples/pdf directory. In particular I think GoJS/samples/pdf/minimalPDFmultiDiagram.html at master · NorthwoodsSoftware/GoJS · GitHub should be of interest to you.