String matching for functions.
KGan opened this issue · comments
string matching here won't work if the worker file defines its export function without a space, since the toString will always inject a space. Will happen very often with code minifiers.
(function(e){}).toString() // produces "function (e){}"
A quick fix will be to name the anonymous function (and make sure there is no white space between the name and the parenthesis => (function a (e){}).toString() // produces "function a(e){}"
). It doesn't seem like I can do here something. Any ideas ?
I added this to the caveats section in the README so I'm closing it unless there will be some idea.
Thanks !