@incajs/cli 0.0.18 → 0.0.20

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.
@@ -0,0 +1,20 @@
1
+ export interface PrintConfigOptions {
2
+ /** The app's root directory. Defaults to `process.cwd()`. */
3
+ cwd?: string;
4
+ /** Overrides host binary resolution. */
5
+ hostBin?: string;
6
+ /** Receives the settings. Defaults to `process.stdout`. */
7
+ stdout?: NodeJS.WritableStream;
8
+ /** Receives the host's own report when it names no setting. Defaults to `process.stderr`. */
9
+ stderr?: NodeJS.WritableStream;
10
+ }
11
+ /**
12
+ * Prints the settings the host applies to the app as JSON. The host reads the app's config from
13
+ * `node_modules/.inca/config/inca.json`, written as a build writes it beside the bundle.
14
+ *
15
+ * @returns the host's exit code: 0 after printing, non-zero when the host refused the config
16
+ * with a report that names no setting, written to `stderr`
17
+ * @throws if the config can't be loaded, a setting holds a value the host can't use, or the
18
+ * host binary can't be resolved, isn't a file or can't be started
19
+ */
20
+ export declare function printConfig(options?: PrintConfigOptions): Promise<number>;
package/dist/types.d.mts CHANGED
@@ -85,8 +85,14 @@ export interface HmrOptions {
85
85
  quiet?: boolean;
86
86
  /** Delivers a bundler payload to the running app over the dev channel. */
87
87
  notify: (payload: unknown) => void;
88
- /** Called in place of forwarding a whole-app reload payload to the app. */
89
- reload: () => void;
88
+ /**
89
+ * Called in place of forwarding a whole-app reload payload to the app, with
90
+ * the edit that caused it when one was waiting.
91
+ */
92
+ reload: (changed?: {
93
+ file: string;
94
+ at: number;
95
+ }) => void;
90
96
  /** Called when an update the app fetched failed to compile. */
91
97
  onError: (error: BuildFailure) => void;
92
98
  /** Called after a successful update, with the file that changed and how long it took. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@incajs/cli",
3
- "version": "0.0.18",
3
+ "version": "0.0.20",
4
4
  "description": "Commands to develop, bundle, and package Incarnative.js apps.",
5
5
  "keywords": [
6
6
  "bundler",
@@ -72,10 +72,10 @@
72
72
  }
73
73
  },
74
74
  "optionalDependencies": {
75
- "@incajs/host-darwin-arm64": "0.0.18",
76
- "@incajs/host-darwin-x64": "0.0.18",
77
- "@incajs/host-linux-arm64": "0.0.18",
78
- "@incajs/host-linux-x64": "0.0.18"
75
+ "@incajs/host-darwin-arm64": "0.0.20",
76
+ "@incajs/host-darwin-x64": "0.0.20",
77
+ "@incajs/host-linux-arm64": "0.0.20",
78
+ "@incajs/host-linux-x64": "0.0.20"
79
79
  },
80
80
  "engines": {
81
81
  "node": ">=22.18"