REditorSupport / vscode-R

R Extension for Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=REditorSupport.r
MIT License
1.05k stars 122 forks source link

pkg dev: devel help page does not open #383

Open pat-s opened 3 years ago

pat-s commented 3 years ago

When developing a package and calling devtools::load_all() and afterwards trying to open the help page of a function, the webview does not open.

devtools::load_all()
?<fun>
Rendering development documentation for '<fun>'

does not work while

library(<pkg>)
?<fun>

works.

renkun-ken commented 3 years ago

Thanks for reporting! I could reproduce this. It looks like this is caused by the development documentation is calling browser() with an html file while rendered documentation is calling browser() with an http web address.

Currently, the browser function vscode-R provides only works with a localhost http web address. And .vsc.viewer to view the htmlwidgets could be used to show such HTML file in a WebView as I tried, but all the paths in the HTML must be substituted with vscode-resource:// to work in WebView or the resource would not work.

And the theming does not look good under dark theme.

image

I'll think about this problem and see if we could find a nice solution. Suggestions are welcome.

assignUser commented 3 years ago

This is actually quite the issue for me as I am currently reworking the documentation of a package and this makes it difficult to do that in vsc while it would be much easier in rstudio. I am not sure if I can contribute anything as far as a solution goes but I will have a look!

pat-s commented 3 years ago

@renkun-ken Has there been any progress on this in the meantime?

github-actions[bot] commented 2 years ago

This issue is stale because it has been open for 365 days with no activity.

pat-s commented 2 years ago

Unstale

github-actions[bot] commented 1 year ago

This issue is stale because it has been open for 365 days with no activity.

renkun-ken commented 1 year ago

@pat-s Does #1259 help resolve the problem? The help pages could show development version of help pages in an editor tab, just like help pages.

assignUser commented 1 year ago

Nice, that sounds like a great solution!

github-actions[bot] commented 3 weeks ago

This issue is stale because it has been open for 365 days with no activity.