Nimblesite / Nimblesite/typeDiagram
PDF export fails
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 63
- Forks
- 4
- PR merge metrics
- No merged PRs in 30d
Description
Summary
PDF export currently fails. Seems to be related to VS Code runtime does not exposing webview.printToPDF.
Whatever the case may be, we need to fix the export.
Evidence
The extension displays this error notification:
TypeDiagram: PDF export failed - Error: [PDF-PRINT] webview.printToPDF is not available in this VS Code runtime. Requires the Electron-based desktop VS Code.
Source: TypeDiagram
Steps to reproduce
- Open TypeDiagram in a VS Code runtime where
webview.printToPDFis unavailable. - Run the TypeDiagram export to PDF command.
Expected behavior
PDF export succeeds
Actual behavior
The export command fails and shows the error above.
Notes
This appears to be a runtime capability issue. The extension should feature-detect PDF support. If for some reason the user's version of vscode doesn't support this, display an error message to the user what they need to do to support PDF export. Critically, we need to be able to get this working for local development and pipeline tests at least
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the TypeDiagram export to PDF command in a VS Code runtime where webview.printToPDF is unavailable, then trace the export path and its runtime capability check. Done means PDF export works in supported local and pipeline environments, while unsupported runtimes show a clear message explaining the requirement.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- desktop-dev, devtools
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100