mdSilo / mdSilo-app

Lightweight Knowledge Base and Feed Reader.
https://mdsilo.com/
GNU Affero General Public License v3.0
572 stars 39 forks source link

The `__TAURI_POST_MESSAGE__` in init.js was depreciated in tauri 2.0 #697

Open sopaco opened 6 months ago

sopaco commented 6 months ago

the custom plugin script use TAURI_POST_MESSAGE to communicate between the Rust and JavaScript, but this property has changed in tauri since 2.0, see:https://github.com/tauri-apps/tauri/commit/a63e71f9799e9bbc82521d2f17b5238fbf690e89

why not use window.__TAURI__.invoke, a standard api in tauri?

code in tauri framework:

image

code in mdSilo:

image
danloh commented 6 months ago

Thanks for the suggestion.

Still working on the plugin, just do some proof of concept.