@native-sdk/cli 0.9.3 → 0.9.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/build/app.zig +323 -76
- package/build/ts_run.mjs +15 -18
- package/build.zig +83 -8
- package/package.json +14 -10
- package/packages/core/compile-surface/core.ts +1 -0
- package/packages/core/package-lock.json +16 -13
- package/packages/core/package.json +5 -2
- package/packages/core/scripts/compiler_command.mjs +71 -0
- package/packages/core/scripts/compiler_typecheck.mjs +4 -4
- package/packages/core/scripts/embed_markup_c.mjs +25 -0
- package/packages/core/scripts/npm_static_spike.mjs +3 -3
- package/packages/core/scripts/run_external_core_compiler.mjs +21 -10
- package/packages/core/scripts/run_external_service_compiler.mjs +17 -7
- package/packages/core/scripts/vendor_service_packages.mjs +121 -8
- package/packages/core/sdk/core.ts +1 -0
- package/packages/core/sdk/events.d.ts +36 -4
- package/packages/core/sdk/events.ts +49 -6
- package/packages/core/src/checker.ts +106 -10
- package/packages/core/src/modules.ts +6 -2
- package/packages/core/src/sqlite_cli.ts +22 -2
- package/packages/core/src/typed_ast.ts +4 -2
- package/packages/core/src/types.ts +8 -8
- package/schemas/app.schema.json +435 -0
- package/skill-data/core/SKILL.md +53 -15
- package/skill-data/core/references/project-anatomy.md +6 -6
- package/skill-data/native-ui/SKILL.md +28 -6
- package/skill-data/ts-core/SKILL.md +9 -6
- package/skill-data/ts-services/references/service-surface.md +1 -1
- package/skills/native-sdk/SKILL.md +2 -2
- package/src/app_runner/ts_core_main.zig +12 -4
- package/src/app_runner/ts_core_mobile.zig +6 -2
- package/src/automation/snapshot.zig +91 -3
- package/src/platform/macos/appkit_host.h +41 -2
- package/src/platform/macos/appkit_host.m +198 -9
- package/src/platform/macos/cef_host.mm +191 -9
- package/src/platform/macos/root.zig +110 -3
- package/src/platform/null_platform.zig +50 -1
- package/src/platform/null_platform_tests.zig +53 -0
- package/src/platform/root.zig +9 -0
- package/src/platform/types.zig +58 -0
- package/src/platform/windows/root.zig +88 -15
- package/src/primitives/canvas/reference.zig +37 -15
- package/src/primitives/canvas/reference_tests.zig +63 -0
- package/src/primitives/canvas/ui.zig +9 -0
- package/src/primitives/canvas/ui_markup.zig +29 -0
- package/src/primitives/canvas/ui_markup_compiled.zig +32 -0
- package/src/primitives/canvas/ui_markup_compiled_tests.zig +4 -2
- package/src/primitives/canvas/ui_markup_contract.zig +7 -0
- package/src/primitives/canvas/ui_markup_contract_tests.zig +21 -0
- package/src/primitives/canvas/ui_markup_tests.zig +6 -0
- package/src/primitives/canvas/ui_markup_view.zig +28 -0
- package/src/primitives/canvas/ui_markup_view_tests.zig +32 -3
- package/src/primitives/canvas/ui_schema.zig +9 -0
- package/src/primitives/canvas/ui_schema_tests.zig +5 -3
- package/src/primitives/canvas/ui_tests.zig +4 -2
- package/src/primitives/canvas/widget_render.zig +7 -2
- package/src/primitives/canvas/widget_semantics_tests.zig +3 -1
- package/src/root.zig +4 -0
- package/src/runtime/automation_snapshot.zig +3 -0
- package/src/runtime/flow.zig +1 -1
- package/src/runtime/state.zig +14 -0
- package/src/runtime/system_services.zig +62 -0
- package/src/runtime/ts_ui_app.zig +181 -39
- package/src/runtime/ui_app.zig +40 -1
- package/src/runtime/ui_app_tests.zig +63 -0
- package/src/runtime/ui_app_window_tests.zig +23 -0
- package/src/runtime/validation.zig +87 -1
- package/src/tooling/android.zig +5 -4
- package/src/tooling/buildgraph.zig +24 -8
- package/src/tooling/db.zig +1 -1
- package/src/tooling/doctor.zig +1 -1
- package/src/tooling/ios.zig +5 -4
- package/src/tooling/json_to_zon.zig +136 -0
- package/src/tooling/manifest.zig +120 -33
- package/src/tooling/raw_manifest.zig +4 -0
- package/src/tooling/root.zig +1 -0
- package/src/tooling/templates.zig +171 -118
- package/src/tooling/ts_core.zig +12 -8
- package/src/tooling/verbs.zig +233 -5
- package/src/tooling/web_engine.zig +17 -1
- package/tools/corewire/emit_profile.zig +20 -7
- package/tools/corewire/emit_service.zig +49 -24
- package/tools/corewire/main.zig +21 -2
package/README.md
CHANGED
|
@@ -20,7 +20,7 @@ cd my_app
|
|
|
20
20
|
native dev
|
|
21
21
|
```
|
|
22
22
|
|
|
23
|
-
A native window opens with a working counter. The primary scaffold is three files of truth and no build config: `src/core.ts` (`Model`, `Msg`, `update`), `src/app.native` (the UI), and `app.
|
|
23
|
+
A native window opens with a working counter. The primary scaffold is three files of truth and no build config: `src/core.ts` (`Model`, `Msg`, `update`), `src/app.native` (the UI), and `app.json` (the manifest, with JSON Schema completion). Existing `app.zon` manifests remain supported. `native dev|build|test` own the generated build; `src/app.native` hot-reloads while the app runs, keeping your state; `native dev --core` runs the TypeScript logic loop under node; and `native check` validates the core and every view in milliseconds without building. Prefer a Zig core? Use `native init my_app --template zig-core`.
|
|
24
24
|
|
|
25
25
|
When part of your product is the web, WebView surfaces coexist with the native canvas; web-frontend scaffolds (`--frontend next`, `--frontend vite`, and more) install their generated frontend dependencies automatically on first run.
|
|
26
26
|
|
|
@@ -34,11 +34,11 @@ Read the full guide at [native-sdk.dev/quick-start](https://native-sdk.dev/quick
|
|
|
34
34
|
| `native dev [dir]` | Build and run the app (markup hot reload; managed frontend dev server when configured) |
|
|
35
35
|
| `native build [dir]` | Build a ReleaseFast binary into `zig-out/bin/` |
|
|
36
36
|
| `native test [dir]` | Run the app's test suite |
|
|
37
|
-
| `native check [dir]` | Validate `src/**.native` markup and `app.zon` against the model contract |
|
|
37
|
+
| `native check [dir]` | Validate `src/**.native` markup and `app.json`/`app.zon` against the model contract |
|
|
38
38
|
| `native markup check\|lsp` | Check individual markup files, or serve diagnostics, completion, and hover to your editor |
|
|
39
39
|
| `native eject [dir]` | Write an owned build.zig/build.zig.zon into the app |
|
|
40
40
|
| `native doctor` | Check host environment, WebView, manifest, and CEF |
|
|
41
|
-
| `native validate` | Validate `app.zon` against the manifest schema |
|
|
41
|
+
| `native validate` | Validate `app.json` (or `app.zon`) against the manifest schema |
|
|
42
42
|
| `native package` | Package the app for distribution |
|
|
43
43
|
| `native bundle-assets` | Copy frontend assets into the build output |
|
|
44
44
|
| `native automate` | Drive a running app: snapshots, widgets, assertions, screenshots, record/replay |
|