Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Functions are undefined #2

Open
NfNitLoop opened this issue Jul 1, 2021 · 0 comments
Open

Functions are undefined #2

NfNitLoop opened this issue Jul 1, 2021 · 0 comments

Comments

@NfNitLoop
Copy link

I've got a gist here w/ sample code:
https://gist.github.com/NfNitLoop/201cc0b816facf176de3ce1ff5890467

which you can run with:

deno run https://gist.githubusercontent.com/NfNitLoop/201cc0b816facf176de3ce1ff5890467/raw/80e8e7550de49defbbbce9b0e5f3a5d03217b1f7/example.ts

But it looks like the functions are undefined. ohhhhh, I've got to await sodium.ready! 🤦‍♂️

Maybe it would be a helpful feature to have them start with some placeholder function like

function() { 
    throw `You must 'await sodium.ready' before using functions.`
}

That way people like me who forget that part get some help? :)

(Thanks for this library, in either case!)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant