Building for platforms

waid build turns your app into a shippable artifact. With no --target it builds just the web bundle; with a --target it produces the native app for that platform.

Sign in with waid login first. Builds default to development mode; select --mode production explicitly for production configuration. Every --release build requires an explicit mode.

bash
# Web bundle only
waid build --src . --mode production
 
# Native app for a platform
waid build --src . --target android
waid build --src . --target ios
waid build --src . --target macos
FlagWhat it does
--src <dir>Your project. Defaults to the current directory.
--target <platform>android, ios, macos, windows, linux, or desktop for the current host. Omit for web only.
--mode <name>Vite configuration mode. Defaults to development; required with --release.
--runtime-dir <dir>The native runtime to embed (see below).
--out <dir>Custom output directory.

Native builds run the platform toolchain (Gradle / Xcode) and can take a while.

Platforms you can ship to#

PlatformDelivery
AndroidAn APK (default) or AAB App Bundle for the Play Store.
iOSAn app for a device (default) or the simulator.
DesktopA macOS .app/DMG, Windows installer, or Linux package.
BrowserA static web bundle, deploy to any web host; no runtime needed.

The runtime directory#

Native builds embed a small rendering runtime for the target platform. Point WAID at it with --runtime-dir <dir> (or the WAID_RUNTIME_DIR environment variable). The directory holds one folder per platform: <dir>/android, <dir>/ios, <dir>/desktop.

WAID resolves the runtime when no override is supplied. Use an explicit runtime directory when testing a runtime build supplied by your team.

Where the output goes#

text
.waid/build/web-package/web/ # web bundle (no --target)
.waid/build/android/<name>.apk # Android APK
.waid/build/android/<name>.aab # Android App Bundle
.waid/build/ios/ # iOS app
.waid/build/macos/ # macOS .app and DMG
.waid/build/windows/ # Windows bundle
.waid/build/linux/ # Linux bundle

Everything under .waid/ is generated, so don't commit it.

Next: Android release · iOS builds · Deploy to a device.