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
This would make the two result types more consistent. We should also include conversion types between the two if possible
Also need to test if once the change is good, you can just return a golem-ts Result in your wit world exported functions, instead of converting back and forth. would be great if we can support this
The text was updated successfully, but these errors were encountered:
nicoburniske
changed the title
We should mirror JCO generated Result type
Mirror JCO generated Result type
Aug 27, 2024
value field should always contain the success value, or the error
there should be a field "tag" that is either "ok" or "err" like the type generated by JCO
See here https://github.com/golemcloud/jco/blob/085e0b32eaa91e9b2e1783dc56515f61fc62583f/crates/js-component-bindgen/src/ts_stubgen.rs#L498
This would make the two result types more consistent. We should also include conversion types between the two if possible
Also need to test if once the change is good, you can just return a golem-ts Result in your wit world exported functions, instead of converting back and forth. would be great if we can support this
The text was updated successfully, but these errors were encountered: