PyWebIO icon indicating copy to clipboard operation
PyWebIO copied to clipboard

[Feature Request] Provide ability to add script tags or any html to `<header>` directly

Open ngshiheng opened this issue 5 years ago • 1 comments

Please move to Discussions - Feature Request for posting.

Currently, the temporary solution is to do:

$('head').append('<link rel="icon" type="image/x-icon" href="xxxxx">')
$('head').append('<script async src="https://xxxxxxxx"></script>')

I am hoping we could get a more direct way of adding scripts or any HTML to tag directly without having to use run_js and append to head tag.

ngshiheng avatar Jun 12 '21 01:06 ngshiheng

pywebio.config(js_code=...) did this.

See https://pywebio.readthedocs.io/en/latest/platform.html#pywebio.config

wang0618 avatar Feb 14 '25 14:02 wang0618