@tauri-apps/api-v2.12.0

ed-donner/llm_engineering@tauri-apps/api-v2.12.0Sep 26, 2026by github-actions[bot]

Upgrading?

AI Summary

This release introduces new window management capabilities, explicit resource management syntax, and fixes for background color handling.

Key Highlights

  • New `exit` function for apps without the process plugin
  • Fullscreen on specific monitor functionality
  • New Liquid Glass window effects (Regular, Clear, and interactive)
  • Explicit Resource Management support via `using` syntax
  • Fix for background color argument serialization

New Features

  • Added `exit` function to `@tauri-apps/api/app`
  • Added `noRedirectionBitmap` option to Window constructors
  • Added `set_fullscreen_on_monitor` API methods
  • Added `Regular` and `Clear` Liquid Glass window effects
  • Added Explicit Resource Management support

Full Release Notes

<details>
<summary><em><h4>PNPM Audit</h4></em></summary>

```
All found vulnerabilities were already reviewed and decided to be ignored
2 ignored: 2 high
```

</details>

## [2.12.0]

### New Features

- [`d8d02ba60`](https://www.github.com/tauri-apps/tauri/commit/d8d02ba60c041fb0ab4f5631e8ea21ce7231a95a) ([#14767](https://www.github.com/tauri-apps/tauri/pull/14767)) Added the `exit` function to `@tauri-apps/api/app`, backed by the new `plugin:app|exit` command (`core:app:allow-exit` permission), to exit the app without requiring the `@tauri-apps/plugin-process` plugin.
- [`990f77eb2`](https://www.github.com/tauri-apps/tauri/commit/990f77eb2f16b431dd5fd8b1059e6112647cca7a) ([#15961](https://www.github.com/tauri-apps/tauri/pull/15961)) Added `JsImage` type alias and documented its relationship to the Rust `JsImage`
- [`29265557c`](https://www.github.com/tauri-apps/tauri/commit/29265557c7a42ef6a1f982e0ef738208df1f6dd3) ([#15410](https://www.github.com/tauri-apps/tauri/pull/15410)) Added `noRedirectionBitmap` option to the `Window` and `WebviewWindow` constructors on Windows.
- [`6edc2f4d4`](https://www.github.com/tauri-apps/tauri/commit/6edc2f4d49d2477649bf170aa2867276c25573da) ([#14926](https://www.github.com/tauri-apps/tauri/pull/14926)) Added `Window::set_fullscreen_on_monitor`, `WebviewWindow::set_fullscreen_on_monitor` and the `setFullscreenOnMonitor` JavaScript API to make a window fullscreen on the monitor containing a given physical position, along with the `core:window:allow-set-fullscreen-on-monitor` permission.

### Enhancements

- [`be019795a`](https://www.github.com/tauri-apps/tauri/commit/be019795abc0316aa53f2519bfbf3e7624b9af2e) ([#14103](https://www.github.com/tauri-apps/tauri/pull/14103)) Add ECMAScript Explicit Resource Management to Resource. You can now use the `using` syntax in supported browsers or with polyfills:
    
    ```javascript
    import { create, BaseDirectory } from "@tauri-apps/plugin-fs"
    ...
    {
      await using file = await create("foo/bar.txt", { baseDir: BaseDirectory.AppConfig });
      await file.write(new TextEncoder().encode("Hello world"));
      // Before `file` goes out of scope, it is disposed by calling `file[Symbol.asyncDispose]()` and awaited.
    }
    ```
- [`4a5065653`](https://www.github.com/tauri-apps/tauri/commit/4a506565374a6a0b4b595e4cdb6d7db68136d765) ([#14454](https://www.github.com/tauri-apps/tauri/pull/14454)) Added `Regular` and `Clear` Liquid Glass window effects, and the `interactive` window effects option (macOS 27.0+) that enables the glass' visual response to user interactions.

### Bug Fixes

- [`4fabe2ff1`](https://www.github.com/tauri-apps/tauri/commit/4fabe2ff1bfe28bbcd3335546caf7db7ff970706) ([#16067](https://www.github.com/tauri-apps/tauri/pull/16067)) Fix `Window.setBackgroundColor`, `Webview.setBackgroundColor` and `WebviewWindow.setBackgroundColor` sending a `color` argument while the `plugin:window|set_background_color` and `plugin:webview|set_webview_background_color` commands expect `label` and `value`. The color was always deserialized as `None`, so instead of applying the given color the call cleared the background of the calling window/webview.
- [`32efd0232`](https://www.github.com/tauri-apps/tauri/commit/32efd0232d868984ac8de9efebae19e464c7c536) ([#15957](https://www.github.com/tauri-apps/tauri/pull/15957)) `Image.rgba` now returns a more specific type `Promise<Uint8Array<ArrayBuffer>>` instead of the default `Promise<Uint8Array<ArrayBufferLike>`

<details>
<summary><em><h4>PNPM Publish</h4></em></summary>

```
$ pnpm build && cd ./dist && pnpm publish --access public --loglevel debug --no-git-checks
$ rollup -c --configPlugin typescript

./src/app.ts, ./src/core.ts, ./src/dpi.ts, ./src/event.ts, ./src/image.ts, ./src/index.ts, ./src/menu.ts, ./src/mocks.ts, ./src/path.ts, ./src/tray.ts, ./src/webview.ts, ./src/webviewWindow.ts, ./src/window.ts → ./dist, ./dist...
created ./dist, ./dist in 757ms

src/index.ts → ../../crates/tauri/scripts/bundle.global.js...
created ../../crates/tauri/scripts/bundle.global.js in 1.1s
GET https://run-actions-2-azure-eastus.actions.githubusercontent.com/182//idtoken/94844eb2-5ce6-4977-8b2e-11a4e27f6498/cd79c963-1235-5e22-9178-857a52efe18b?api-version=2.0&audience=npm%3Aregistry.npmjs.org 200 280ms
šŸ“¦ @tauri-apps/api@2.12.0 → https://registry.npmjs.org/
GET https://run-actions-2-azure-eastus.actions.githubusercontent.com/182//idtoken/94844eb2-5ce6-4977-8b2e-11a4e27f6498/cd79c963-1235-5e22-9178-857a52efe18b?api-version=2.0&audience=sigstore 200 96ms
Signed provenance statement with source and build information
āœ… Published package @tauri-apps/api@2.12.0
```

</details>

Related Repositories