mateuszmigas / painting-droid

AI-powered cross-platform painting app inspired by the legendary MS Paint.
https://www.paintingdroid.com
GNU General Public License v3.0
116 stars 3 forks source link

Refactor core to return results from rust to typescript #3

Closed mateuszmigas closed 5 months ago

mateuszmigas commented 5 months ago

Please describe the problem. Currently, we return Vec from core as a result. This is not optimal because an error could occur. Returning a result is a more stable approach than throwing exceptions.

Describe the solution you'd like Return Result<Value, String> instead.

Describe alternatives you've considered N/A

Additional context Remember to mark methods with [wasm-binden] so they are exported in wasm interface.