It currently only has any for the function return type. Instead, we could have developers define the callback with an onComplete wrapper instead of internalMutation:
export const exampleCallback = onComplete({
action: internal.index.exampleAction,
handler: async (ctx, args) => {
});
Then, args would have its type specified precisely.
To support custom functions, onComplete could take in internalMutation:
const onComplete = makeOnComplete(internalMutation);
It currently only has
anyfor the function return type. Instead, we could have developers define the callback with anonCompletewrapper instead ofinternalMutation:Then,
argswould have its type specified precisely.To support custom functions,
onCompletecould take ininternalMutation: