yzane / vscode-markdown-pdf

Markdown converter for Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=yzane.markdown-pdf
Other
1.01k stars 206 forks source link

plantuml diagram with !include does not render #241

Open asio opened 3 years ago

asio commented 3 years ago

The following markdown file will show the diagram correctly within vs code preview window

# Some header

some text

```plantuml
@startuml
!include stylesheet.iuml

A->B : text
@enduml

But exporting this to HTML results in the following(with no images showing just the alt text displayed):

```html
<h1 id="some-header">Some header</h1>
<p>some text</p>
<img src="http://localhost:8080/svg/SoWkIImgAStDuNA0inGpyv9pIbDI5OfBAdDIYpDIKqlqCa4IN8wwTauALWebgHKbN0wfUIbWVH0Q0000" alt="uml diagram">

And a PDF exports gives:

PlantUML 1.2021.2
[From string (line 2) ]
@startuml
!include stylesheet.iuml
cannot include stylesheet.iuml

Settings:

  "markdown-pdf.plantumlServer": "http://localhost:8080",
  "markdown-pdf.plantumlOpenMarker": "```plantuml",
  "markdown-pdf.plantumlCloseMarker": "```",
  "plantuml.server": "http://localhost:8080",
  "plantuml.includepaths": ["C:\\opt\\workspace\\projectXXX\\documentation\\resources\\plantuml"],
  //                                                         ^-- This is the root of workspace
apgdjr commented 2 years ago

I have the same issue, but when I change from Local server to http://www.plantuml.com/plantuml it worked... Still trying to figure out how to solve it using a local server