You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Actually simplifies our types further (due to the lack of this)
Somewhat matches other patterns like:
import.meta.url;// Only available in the current file, in ES ModulesfunctiononMessageHandler(){if(chrome.runtime.lastError){// Available only in this call}}
Nope, I just realized that this could only work in sync functions, because a second message could replace currentMeta before first call returns. Even if I were to store each meta for each call, there's no way to match a meta with a call without passing a parameter… which would probably be this anyway:
Information about the sender/trace and options is currently stored on
this
. This is because:arguments[0]
is the meta")this
is fine for me, but maybe there alternative solutions. This is what I came up with:This pattern:
this
)The implementation would look like:
and
The text was updated successfully, but these errors were encountered: