The relationship between the versions of npm library and Cargo crate when publishing plugins #14483
-
|
When developing a Tauri plugin, if we publish the JavaScript bindings as an npm library and the Rust-side functionality as a crate on crates.io, is it necessary to align the version of the npm library with the version of the crate? For example, if the Rust crate tauri-plugin-anything is at version 3.3.0, is it possible for its JavaScript binding, the npm library tauri-plugin-anything-api, to be at version 1.0.0? Or to be at version 3.0.0? Previously, when building a Tauri app using another plugin, I encountered an error complaining about a version mismatch between the npm library and the Rust crate, so I became concerned. Thank you :> |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
In theory it doesn't have to align but we strongly recommend it and adapted this practice in the official plugins a while ago after quite a lot of user feedback. We now have tons of empty releases on one side but at least it's easy for users to sync compatible versions. But yeah, this is personal preference for the plugin author (you). |
Beta Was this translation helpful? Give feedback.
In theory it doesn't have to align but we strongly recommend it and adapted this practice in the official plugins a while ago after quite a lot of user feedback.
We now have tons of empty releases on one side but at least it's easy for users to sync compatible versions. But yeah, this is personal preference for the plugin author (you).