From: Ardis Lu Date: Fri, 30 Jun 2023 04:25:30 +0000 (-0700) Subject: Add help to globalThis during definition X-Git-Url: https://git.ardis.lu/?a=commitdiff_plain;h=88ab59ac13c33b9c658c60c86a04093bbb238588;p=static-encrypt Add help to globalThis during definition --- diff --git a/index.html b/index.html index a999a2d..88908ed 100644 --- a/index.html +++ b/index.html @@ -219,14 +219,13 @@ const template = await fetch('/template.html').then(r => r.text()); // For debugging and bulk usage in the DevTools console - function help() { + globalThis.help = function () { console.table({ 'help(): void': 'Print this message.', 'encrypt(plaintext: string, password: string): Promise': 'Encrypt a string.', 'decrypt(content: string, password: string): Promise': 'Decrypt an encrypted string.' }); } - globalThis.help = help; globalThis.encrypt = encrypt; globalThis.decrypt = decrypt; help();