Open
Description
Hi,
Would it be possible to add a Asynchronous evaluator ? I am currently using this libray to call a couple of functions dynamically, however I do have a a couple of functions which are asynchronous in nature. Since the evaluation happens instantly, it immediately resolves the pending promise instead of the value.
So the case would be something like this;
Parser.functions.AsyncCall1 = async function() { const res = await api.getAmount(); return res; }
Parser.functions.AsyncCall2 = async function() { const res = await api.getAmount(); return res; }
Parser.evaluateAsync('AsyncCall1() + AsyncCall2()');
Although I do realize this was not the intended use-case.