sciter-js-sdk icon indicating copy to clipboard operation
sciter-js-sdk copied to clipboard

Issues in mdview

Open DhruvaSambrani opened this issue 3 years ago • 3 comments

I was playing around with the sample to compile to html using pandoc, and came across these issues

File watching

At https://github.com/c-smile/sciter-js-sdk/blob/37851e58eea46c9ecc15500bfbe41971b66ddbd9/samples.sciter/applications.quark/mdview/main.js#L180 it should be Settings.saveState()

Rendering images

Any images added as ![alt-text](./relative/link) do not resolve correctly, and a checkered board is shown(presumably the default image). I'm reasonably sure that this is the same issue as the next one.

Following local links

Links added as [link text](local/file/path.md) are not resolved as a file://but rather as a this://, which leads the app to ask the os to handle it. While I'm not sure if this is an error in sciter or in my implementation, shouldn't this happen by itself? How do I fix this?

DhruvaSambrani avatar Apr 12 '21 22:04 DhruvaSambrani

Also, mathjax doesn't seem to work, with an error "Mathjax(?): not a function". Is this expected? How do I work around this?

DhruvaSambrani avatar Apr 12 '21 22:04 DhruvaSambrani

What does ./ (dot) mean in context of URLs like ./relative/link ?

It has meaning of "current folder" inside linux shells or cmd process in Windows. But in URLs?

c-smile avatar Apr 18 '21 17:04 c-smile

Also, mathjax doesn't seem to work, with an error "Mathjax(?): not a function". Is this expected? How do I work around this?

Mathjax is a plugin. So it will work if you will add that plugin to sources of the mdview.

So far mdview adds just one plugin - HeaderIds

c-smile avatar Apr 18 '21 17:04 c-smile