jffi 0.4.13

Cross-platform framework for building native apps with Rust business logic and platform-native UIs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use uniffi;

#[derive(uniffi::Object)]
pub struct Core {}

#[uniffi::export]
impl Core {
    #[uniffi::constructor]
    pub fn new() -> Self {
        Self {}
    }

    pub fn greeting(&self) -> String {
        "{{greeting}}".to_string()
    }
}

uniffi::setup_scaffolding!();