📜  Scratch Addon 用户脚本 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:03:42.878000             🧑  作者: Mango

代码示例1
export default async function ({ addon, global, console }) {
  // This WON'T work!
  sayHello();
}
function sayHello() {
  console.log("Hello, " + addon.auth.username);
  // Error: addon is not defined!
}