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
Hello,
when trying to create a Dynamic node based on the example here, I get a Typescript error. The example works though, I was just wondering about how to get rid of the error.
Type '({ operation }: { operation: string; }) => { inputs: { input1: () => NumberInterface; input2?: undefined; }; } | { inputs: { input1: () => NumberInterface; input2: () => NumberInterface; }; }' is not assignable to type '(inputs: { operation: string; }, outputs: { result: number; }) => DynamicNodeUpdateResult'.
Type '{ inputs: { input1: () => NumberInterface; input2?: undefined; }; } | { inputs: { input1: () => NumberInterface; input2: () => NumberInterface; }; }' is not assignable to type 'DynamicNodeUpdateResult'.
Type '{ inputs: { input1: () => NumberInterface; input2?: undefined; }; }' is not assignable to type 'DynamicNodeUpdateResult'.
Types of property 'inputs' are incompatible.
Type '{ input1: () => NumberInterface; input2?: undefined; }' is not assignable to type 'DynamicNodeDefinition'.
Property 'input2' is incompatible with index signature.
Type 'undefined' is not assignable to type '() => NodeInterface<any>'.ts(2322)
The text was updated successfully, but these errors were encountered:
Thanks for the issue, this will be fixed in the next release. For now, you can add as DynamicNodeDefinition to the return value of the onUpdate function, like this:
Hello,
when trying to create a Dynamic node based on the example here, I get a Typescript error. The example works though, I was just wondering about how to get rid of the error.
The text was updated successfully, but these errors were encountered: