-
Notifications
You must be signed in to change notification settings - Fork 20
Open
Description
When trying to set the icon using ``webui.setIcon()` the icon does not get set. This is my code:
import { WebUI } from '@webui/deno-webui'
import icon from '../client/static/favicon.svg' with {type: 'text'}
import { parseArgs } from '@std/cli/parse-args';
const args = parseArgs<{
develop : boolean | undefined
}>(Deno.args);
const client = new WebUI();
client.setIcon(icon, 'image/svg+xml')
client.setRootFolder('./dist');
client.bind('', (event: WebUI.Event) => {
console.log(event);
})
client.bind('exit', () => {
client.close();
});
if (args.develop) {
client.showBrowser('index.html', WebUI.Browser.Chrome);
} else {
client.show('index.html');
}
await WebUI.wait();I can verify that the import is working by logging the icon variable. Also inserting the SVG file directly as a string does not work. Am I doing something wrong? When running webui uses WebView2 on Windows, and it looks like the icon get's not set correctly for WebView2.
Here is my template if anyone is interested.
Thanks
Metadata
Metadata
Assignees
Labels
No labels