Skip to main content

Jac-native desktop target: one nacompile'd binary + the OS webview.

Project description

jac-desktop

Jac-native desktop target for Jac: a desktop app is one jac nacompiled binary + the OS's own web engine - no Rust toolchain, no PyInstaller, no separate process.

What you get

  • A desktop build target registered with jac-client's target registry, so jac build --client desktop and jac start --client desktop work once this package is installed.
  • The build pipeline:
    1. builds your cl codespace with the standard Vite pipeline (via WebTarget),
    2. compiles a native host (na) that embeds CPython to serve that bundle on a loopback port and renders it in the OS-native webview (WebKitGTK on Linux / WKWebView on macOS / WebView2 on Windows),
    3. produces a single self-contained binary under .jac/client/desktop/.

The native webview binding + build tooling live under jac_desktop/native/webview/ (see its README for the phase-by-phase design and the dependency-free test suite).

Install

pip install jac-client jac-desktop

Building a desktop app needs the OS web engine + a C toolchain so the native host can link libwebview.so (built on first use). On Debian/Ubuntu:

sudo ./jac_desktop/native/webview/install_webkit_deps.sh
# (build-essential, pkg-config, libgtk-3-dev, libwebkit2gtk-4.1-dev)

Project flow

jac create --use fullstack my-app      # or any project with a cl codespace
cd my-app
jac build --client desktop             # -> .jac/client/desktop/<app>  (single binary)
jac start --client desktop             # build + launch the native window

Window geometry + app identity come from [plugins.desktop] in jac.toml:

[plugins.desktop]
name = "my-app"

[plugins.desktop.window]
title = "My App"
width = 1000
height = 700

Status

jac build --client desktop produces a working, self-contained native desktop binary that renders your cl UI. The host embeds CPython (it serves the bundle and is where sv runs in-process). Remaining: wiring the sv codespace/walkers onto the embedded interpreter, HMR dev mode, and per-OS packaging/signing - see issue #6436.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

jac_desktop-0.2.2.tar.gz (110.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

jac_desktop-0.2.2-py3-none-any.whl (299.4 kB view details)

Uploaded Python 3

File details

Details for the file jac_desktop-0.2.2.tar.gz.

File metadata

  • Download URL: jac_desktop-0.2.2.tar.gz
  • Upload date:
  • Size: 110.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for jac_desktop-0.2.2.tar.gz
Algorithm Hash digest
SHA256 4fb676decd084a30a1563ae7b57d2103a555ecaed55a88cf42f131a98bf9aa57
MD5 3fa649394a7e8d07499ef603407582b5
BLAKE2b-256 5db902338b021437b059380f007aef9698d1263227995799dd4a2c280d08aa23

See more details on using hashes here.

File details

Details for the file jac_desktop-0.2.2-py3-none-any.whl.

File metadata

  • Download URL: jac_desktop-0.2.2-py3-none-any.whl
  • Upload date:
  • Size: 299.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for jac_desktop-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 548b72e7753fdc374718372373bbb046fa69a0c12025b941421480bb89c906ba
MD5 6ce4d2e5e310f26dc9a01c42a6a872d2
BLAKE2b-256 b6110a9a699982b0a9ad10f8fe597910c4523359deaedfb7d19ecdc88685488a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page