mirror of
https://github.com/pyscript/pyscript.git
synced 2026-03-14 04:00:02 -04:00
More plugins: splashscreen and importmap (#938)
This PR move codes from main.ts into two new plugins: - splashscreen (formerly known as py-loader) - importmap The old setting config.autoclose_loader is still supported but deprecated; the new setting is config.splashscreen.autoclose. Moreover, it does a small refactoring around UserError: now UserErrors are correctly caught even if they are raised from within afterRuntimeLoad.
This commit is contained in:
@@ -21,8 +21,6 @@
|
||||
files = ["./utils.py"]
|
||||
</py-config>
|
||||
<py-script output="outputDiv">
|
||||
# demonstrates how use the global PyScript pyscript_loader
|
||||
# to send operation log messages to it
|
||||
import utils
|
||||
display(utils.now())
|
||||
</py-script>
|
||||
@@ -43,8 +41,6 @@ async def foo():
|
||||
else:
|
||||
out3.clear()
|
||||
|
||||
# close the global PyScript pyscript_loader
|
||||
pyscript_loader.close()
|
||||
pyscript.run_until_complete(foo())
|
||||
</py-script>
|
||||
</body>
|
||||
|
||||
Reference in New Issue
Block a user