Comments (11)
When the preview is opened, open the command palette (https://code.visualstudio.com/docs/getstarted/tips-and-tricks#_command-palette) and search for "Manage Preview Security Settings".
I tried this.
When preview security setting was "Allow insecure local content", the preview of plantuml was shown in also v3.9.7!
Thank you for telling it to me!
My problems were all solved:)
from asciidoctor-vscode.
:kroki-fetch-diagram:
is not supported when running Asciidoctor Kroki in VS Code. The reason is that unxhr
does not work in VS Code: ggrossetie/unxhr#98
With the following configuration:
"asciidoc.preview.asciidoctorAttributes": {
"allow-uri-read": true,
"kroki-fetch-diagram": true
}
Asciidoctor Kroki won't work with either kroki.io or local instance.
I've updated the documentation: #820
from asciidoctor-vscode.
@ggrossetie Thank you for replying.
I'd like to use local kroki to preview plantuml diagrams on asciidoc preview.
I understood ‘kroki-fetch-diagram‘ is necessary to do that, but unfortunately it's not supported.
Do you have any alternative solutions to preview plantuml diagrams with local kroki than ‘kroki-fetch-diagram‘?
from asciidoctor-vscode.
I'd like to use local kroki to preview plantuml diagrams on asciidoc preview.
I understood ‘kroki-fetch-diagram‘ is necessary to do that, but unfortunately it's not supported.
You don't need kroki-fetch-diagram
to use a local Kroki instance. This option is useful for publishing an HTML document without having a dependency on a Kroki instance. If it's just for local preview, there's no need for kroki-fetch-diagram
. Otherwise, I recommend exporting to HTML outside of VS Code using the asciidoctor
command line (where the kroki-fetch-diagram
will work).
Did you understand that the option was necessary while reading the documentation? Maybe we need to clarify that.
from asciidoctor-vscode.
@ggrossetie
I understand that ‘kroki-fetch-diagram‘ was necessary based on the actual behavior of the extension, not from the documents.
I'll write "actual behavior".
With ‘kroki-fetch-diagram‘ diagrams were shown in the preview and without it diagrams weren't shown.
The version of this extension is v3.1.7.
from asciidoctor-vscode.
Do you still reproduce this issue with the latest version (3.1.8)?
Could you please try to reproduce in a clean environment:
- no other extension
- reset your user and workspace settings
- install latest version of the AsciiDoc extension
- enable Kroki
- create a simple Asciidoc file with a diagram
Thanks!
from asciidoctor-vscode.
@ggrossetie
I tested with below
- no other extension
- reset user settings and add below(This includes enabling kroki.)
{
"asciidoc.extensions.enableKroki": true,
"asciidoc.preview.asciidoctorAttributes": {
"kroki-server-url": "http://localhost:8000"
}
}
- I think the adoc content which I quoted in this issue origin is enough simple.
With v3.1.8
: It works! The diagrams in preview was shown.
With v3.1.7
: It doesn't work.
It seems this issue was fixed in v3.1.8
,
I'd like to know what issue fixed this issue.
Do you know this?
from asciidoctor-vscode.
I made a fix to allow the Kroki server defined in the preview attributes (by adding it to the CSP rules)
Please note that it should also work in 3.1.7 if you disable the preview security.
from asciidoctor-vscode.
Please note that it should also work in 3.1.7 if you disable the preview security.
Excuse me, could you tell me how to disable the.preview security and enable it?
from asciidoctor-vscode.
When the preview is opened, open the command palette (https://code.visualstudio.com/docs/getstarted/tips-and-tricks#_command-palette) and search for "Manage Preview Security Settings".
from asciidoctor-vscode.
Thank you, I'll try it after a few days!
from asciidoctor-vscode.
Related Issues (20)
- Test "Antora support with single documentation component" is flaky HOT 1
- Preview stops working if reference to bibliography entry exists in 3.2.1 HOT 5
- `npm install` reports 9 vulnerabilities on `master` HOT 1
- Quotes have a dark overlay in preview but not in .pdf HOT 4
- `package.json` and `package-lock.json` are not in sync after `prepare branch for development [no ci]` HOT 2
- Add test coverage reporting
- Project README / CHANGELOG is Markdown instead of AsciiDoc
- Asciidoc: Export Document as PDF --> prompts user every time HOT 1
- Preview scroll offset wrong when includes are used HOT 1
- Make error more prominent
- Preview scroll offset wrong when working with tables HOT 1
- Disabling SSL verification HOT 2
- Syntax highlighting broken if a variable is used with bash source
- Preview not rendering checkboxes in checklist
- Ctrl + Alt + V break HOT 1
- [Windows Only][Antora Support] `include::example$something` not working on windows
- Cant use asciidoctor in my own extension as soon as i active asciidoctor-vscode extension HOT 7
- Antora preview doesn't work if version is not specified in antora.yml
- Callout and Syntax Highlighting in code blocks
- Right-click causes incorrect multi-select behavior HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from asciidoctor-vscode.