Fabian-Lars 09b6137d70 Merge v1 into v2 (#468)
Co-authored-by: Fabian-Lars <fabianlars@fabianlars.de>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: FabianLars <fabianlars@fabianlars.de>
Co-authored-by: FabianLars <FabianLars@users.noreply.github.com>
Co-authored-by: Alexandre Dang <124160233+vdang-crabnebula@users.noreply.github.com>
Co-authored-by: Ludea <ludovicw35@hotmail.com>
Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
Co-authored-by: Duke Jones <104690+dukejones@users.noreply.github.com>
Co-authored-by: NaokiM03 <37442712+NaokiM03@users.noreply.github.com>
Co-authored-by: Thibault <thibault_poisson@orange.fr>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: David Blythe <49919035+writeDavid@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
fix(stronghold): change wrong argument name for `remove` (#422)
fix(window-state): correctly set decoration state if no saved state exists, fixes #421 (#424)
fix(stronghold): return null if there is no record (#129)
fix(window-state): propagate promise (#435)
closes #432
fix(window-state): manual default implentation (#425)
fix(window-state): manual default implentation, closes #421
fix(deps): update rust crate iota-crypto to 0.21 (#438)
fix readme example (#447)
fix: handle recursive directory correctly (#455)
fix(deps): update rust crate sqlx to 0.7. plugin-sql msrv is now 1.65 (#464)
fix(persisted-scope): separately save asset protocol patterns (#459)
fix(deps): update rust crate iota-crypto to 0.22 (#475)
fix(deps): update tauri monorepo to v1.4.0 (#482)
resolve to v15.1.0 (#489)
fix(deps): update rust crate iota-crypto to 0.23 (#495)

Committed via a GitHub action: https://github.com/tauri-apps/plugins-workspace/actions/runs/5602434141

Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2023-07-19 17:52:06 +00:00
2023-07-19 17:52:06 +00:00
2023-06-20 11:56:57 +00:00
2023-06-19 11:31:37 +00:00
2023-05-24 13:34:52 +00:00
2023-06-19 11:31:37 +00:00
2023-07-19 17:52:06 +00:00

plugin-app

This plugin provides APIs to read application metadata and macOS app visibility functions.

Install

This plugin requires a Rust version of at least 1.65

There are three general methods of installation that we can recommend.

  1. Use crates.io and npm (easiest, and requires you to trust that our publishing pipeline worked)
  2. Pull sources directly from Github using git tags / revision hashes (most secure)
  3. Git submodule install this repo in your tauri project and then use file protocol to ingest the source (most secure, but inconvenient to use)

Install the Core plugin by adding the following to your Cargo.toml file:

src-tauri/Cargo.toml

[dependencies]
tauri-plugin-app = "2.0.0-alpha"
# alternatively with Git:
tauri-plugin-app = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" }

You can install the JavaScript Guest bindings using your preferred JavaScript package manager:

Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use.

pnpm add @tauri-apps/plugin-app
# or
npm add @tauri-apps/plugin-app
# or
yarn add @tauri-apps/plugin-app

# alternatively with Git:
pnpm add https://github.com/tauri-apps/tauri-plugin-app#v2
# or
npm add https://github.com/tauri-apps/tauri-plugin-app#v2
# or
yarn add https://github.com/tauri-apps/tauri-plugin-app#v2

Usage

First you need to register the core plugin with Tauri:

src-tauri/src/main.rs

fn main() {
    tauri::Builder::default()
        .plugin(tauri_plugin_app::init())
        .run(tauri::generate_context!())
        .expect("error while running tauri application");
}

Afterwards all the plugin's APIs are available through the JavaScript guest bindings:

import { getVersion, hide } from "@tauri-apps/plugin-app";
const appVersion = await getVersion();
await hide();

Contributing

PRs accepted. Please make sure to read the Contributing Guide before making a pull request.

License

Code: (c) 2015 - Present - The Tauri Programme within The Commons Conservancy.

MIT or MIT/Apache 2.0 where applicable.

Description
No description provided
Readme 110 KiB
Languages
JavaScript 34.4%
TypeScript 32.9%
Rust 32.7%