You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 30, 2024. It is now read-only.
We researched this yesterday and shared preliminary info in slack:
looking at the built-in simple browser implementation I don't see a quick and easy way for us to open it on the side, or change that webview title and icon. So, if we want to see more stylized Evidence built-in browser and have more open/close/reload page options, we'd need to invest time into implementing our own. ... https://github.com/microsoft/vscode/blob/main/extensions/simple-browser/src/extension.ts
Also, that Simple Browser webview API doesn't provide close view option, and VS Code itself still doesn't have an API to iterate over all open webviews, only visibleTextEditors list is available. Therefore, it is not possible for us to close Simple Browser, without implementing our own or using another extension like the popular, but not maintained Browser Lite.
The only other quick workaround without investing 2-3 days on implementing your own custom Evidence App webview, is:
Have your app dev team add Start Dev Server "greeting" page to your app ./static folder and standard app template
We can set global state for when we open one of the Evidence pages in a Simple Browser extension, and what page it was on
On VS Code reload and Evidence extension activation, we can show new Start Dev Server "greeting" page in a Simple Browser, so that it doesn't show up blank.
When a user starts a server, we can take them to the last viewed page saved in the global state from the previous Preview session.
and lastly, your app still needs proper Loading ... home page while the server starts and generates pages. I've requested this multiple times in slack and tickets here to address long blank app page view in a browser.
That's a few hours, most likely a day of setup, dev, testing and coordination with the app dev team, if you'd like us to open a UX enhancement ticket to address it this or next week.
On the related note, we can also open new active editor group on the side, and maybe add Preview on the Side for the Simple Browser to show up there. However, changing that built-in browser title and icon is not possible per my read of that built-in vscode extension API referenced above.
The text was updated successfully, but these errors were encountered:
RandomFractals
changed the title
Simpler Browser Limitations and Load/Close webview options
Built-in VS Code Simple Browser Limitations and other Load/Close App Page and webview UI customization options
Jun 1, 2023
@hughess thank you! even a starting static app page with some fancy animation could make it much better while we SSR those pages and modules, and get data.
We researched this yesterday and shared preliminary info in slack:
Also, that Simple Browser webview API doesn't provide close view option, and VS Code itself still doesn't have an API to iterate over all open webviews, only
visibleTextEditors
list is available. Therefore, it is not possible for us to close Simple Browser, without implementing our own or using another extension like the popular, but not maintainedBrowser Lite
.The only other quick workaround without investing 2-3 days on implementing your own custom Evidence App webview, is:
Start Dev Server
"greeting" page to your app./static
folder and standard apptemplate
Start Dev Server
"greeting" page in a Simple Browser, so that it doesn't show up blank.Loading ...
home page while the server starts and generates pages. I've requested this multiple times in slack and tickets here to address long blank app page view in a browser.That's a few hours, most likely a day of setup, dev, testing and coordination with the app dev team, if you'd like us to open a UX enhancement ticket to address it this or next week.
On the related note, we can also open new active editor group on the side, and maybe add
Preview on the Side
for the Simple Browser to show up there. However, changing that built-in browser title and icon is not possible per my read of that built-in vscode extension API referenced above.Originally posted by @RandomFractals in #24 (comment)
The text was updated successfully, but these errors were encountered: