[next] Enabled hooks around plugins (#1522)

This commit is contained in:
Andrea Giammarchi
2023-06-12 22:18:55 +02:00
committed by GitHub
parent bb364b0524
commit da544929ac
10 changed files with 138 additions and 19 deletions

View File

@@ -16,7 +16,7 @@
import { registerPlugin } from "@pyscript/core";
registerPlugin("lua-script", {
type: "wasmoon", // or just 'lua'
async onRuntimeReady(element, wasmoon) {
async onRuntimeReady(wasmoon, element) {
// Somehow this doesn't work in Wasmoon
wasmoon.io.stdout = (message) => {
console.log("🌑", wasmoon.type, message);