tauri-plugin-deno 0.2.0

A tauri 2 plugin to use javascript code (deno) in the backend.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
//  Tauri Plugin Deno
//  © Copyright 2025, by Marco Mengelkoch
//  Licensed under MIT License, see License file for more details
//  git clone https://github.com/marcomq/tauri-plugin-deno

use serde::de::DeserializeOwned;
use tauri::{plugin::PluginApi, AppHandle, Runtime};

pub fn init<R: Runtime, C: DeserializeOwned>(
    app: &AppHandle<R>,
    _api: PluginApi<R, C>,
) -> crate::Result<Deno<R>> {
    Ok(Deno(app.clone()))
}

/// Access to the deno APIs.
pub struct Deno<R: Runtime>(AppHandle<R>);