@nifrajs/cli 2.6.1 → 2.7.0
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/dist/cli.js +1 -1
- package/dist/mcp-http.js +1 -1
- package/docs/llms-full.txt +16 -2
- package/docs/types.json +2 -2
- package/package.json +9 -9
- package/src/cli.ts +1 -1
- package/src/mcp-http.ts +1 -1
package/dist/cli.js
CHANGED
|
@@ -134,7 +134,7 @@ routes/ from the current directory. Run from your project root.
|
|
|
134
134
|
Port: \`dev\` and \`start\` share the default ${DEFAULT_DEV_PORT}. Override with \`--port <n>\` (alias \`-p\`) or the
|
|
135
135
|
\`PORT\` env var (\`--port\` wins over \`PORT\`, which wins over the default).`;
|
|
136
136
|
// Kept in lockstep with packages/cli/package.json by check:publish's version-consistency gate.
|
|
137
|
-
const CLI_VERSION = "2.
|
|
137
|
+
const CLI_VERSION = "2.7.0";
|
|
138
138
|
// A render adapter + nifra server are opaque to the CLI (it just forwards them); cast at the seam.
|
|
139
139
|
const asAdapter = (v) => v;
|
|
140
140
|
const asBunPlugins = (v) => v;
|
package/dist/mcp-http.js
CHANGED
|
@@ -23,7 +23,7 @@ import { loadTypesCorpus } from "./types-search.js";
|
|
|
23
23
|
export { examplesAppTool, examplesWidget } from "./mcp-app-tool.js";
|
|
24
24
|
export { docsTools } from "./mcp-docs-tools.js";
|
|
25
25
|
// Kept in lockstep with packages/cli/package.json by check:publish's version-consistency gate.
|
|
26
|
-
const VERSION = "2.
|
|
26
|
+
const VERSION = "2.7.0";
|
|
27
27
|
const SERVER_INFO = { name: "nifra-docs", version: VERSION };
|
|
28
28
|
// Derive the GET/health tool list from the tools actually served, so the line can never drift from them.
|
|
29
29
|
const docsHealth = (tools) => `nifra docs MCP - POST JSON-RPC 2.0 here (methods: initialize, tools/list, tools/call). Tools: ${tools
|
package/docs/llms-full.txt
CHANGED
|
@@ -3453,6 +3453,16 @@ my-app/
|
|
|
3453
3453
|
backend.ts # export const backend = server()... (optional - the typed contract)
|
|
3454
3454
|
```
|
|
3455
3455
|
|
|
3456
|
+
These paths are **fixed**, not configurable: the CLI resolves all four from the
|
|
3457
|
+
project root, so `backend.ts` cannot move into `src/` or be renamed -
|
|
3458
|
+
if the file is not at the root, `nifra dev|build` simply run without a backend
|
|
3459
|
+
(it is optional, so nothing errors). Only the entry file is pinned; the feature modules it
|
|
3460
|
+
`.merge()`s can live in any directory. Keep `backend.ts` a pure
|
|
3461
|
+
composition root - merging modules, registering no routes of its own - so each route's
|
|
3462
|
+
capability reach stays its own module's (see
|
|
3463
|
+
[Backends & API](/docs/backends) and
|
|
3464
|
+
[Verification](/docs/verification)).
|
|
3465
|
+
|
|
3456
3466
|
### framework.ts - naming the framework once
|
|
3457
3467
|
|
|
3458
3468
|
Keep the render `adapter` in deploy-safe `framework.ts`. Put
|
|
@@ -8416,10 +8426,14 @@ bun create nifra my-app
|
|
|
8416
8426
|
|
|
8417
8427
|
- **`api`** - a typed nifra server (`src/app.ts` + `src/index.ts`) with an example test and
|
|
8418
8428
|
`dev`/`start`/`test`/`typecheck` scripts.
|
|
8419
|
-
- **`site`** - a nifra + React SSR site
|
|
8420
|
-
Vercel Edge.
|
|
8429
|
+
- **`site`** - the full-stack template: a nifra + React SSR site (file-routed frontend + typed
|
|
8430
|
+
`backend.ts`), one source deployable to Cloudflare Pages, Node, Deno, or Vercel Edge. Pick the
|
|
8431
|
+
frontend with `--framework react|preact|vue|solid|svelte`.
|
|
8421
8432
|
- **`isr`** - a nifra + React app with **Incremental Static Regeneration** on Cloudflare Workers + KV
|
|
8422
8433
|
(pages cached + served stale-while-revalidate; on-demand purge endpoint).
|
|
8434
|
+
- **`batteries`** - the `api` starter plus the batteries a real API needs: background jobs
|
|
8435
|
+
(`@nifrajs/jobs`), a TTL cache (`@nifrajs/cache`), blob storage (`@nifrajs/storage`), and cursor
|
|
8436
|
+
pagination (`@nifrajs/schema`).
|
|
8423
8437
|
|
|
8424
8438
|
```sh
|
|
8425
8439
|
bun create nifra my-app --template isr
|
package/docs/types.json
CHANGED
|
@@ -10814,14 +10814,14 @@
|
|
|
10814
10814
|
"name": "VERSION",
|
|
10815
10815
|
"kind": "const",
|
|
10816
10816
|
"package": "@nifrajs/core",
|
|
10817
|
-
"signature": "export declare const VERSION: \"2.
|
|
10817
|
+
"signature": "export declare const VERSION: \"2.7.0\";",
|
|
10818
10818
|
"doc": "/**\n * Current package version. A hardcoded literal on purpose - core runs on the edge (no fs), so it can't\n * read its own package.json at runtime. `scripts/version.ts` rewrites it on every release bump and\n * `check:publish` asserts it equals `@nifrajs/core`'s package version.\n */"
|
|
10819
10819
|
},
|
|
10820
10820
|
{
|
|
10821
10821
|
"name": "VERSION",
|
|
10822
10822
|
"kind": "const",
|
|
10823
10823
|
"package": "nifra",
|
|
10824
|
-
"signature": "export declare const VERSION: \"2.
|
|
10824
|
+
"signature": "export declare const VERSION: \"2.7.0\";",
|
|
10825
10825
|
"doc": "/**\n * Current package version. A hardcoded literal on purpose - core runs on the edge (no fs), so it can't\n * read its own package.json at runtime. `scripts/version.ts` rewrites it on every release bump and\n * `check:publish` asserts it equals `@nifrajs/core`'s package version.\n */"
|
|
10826
10826
|
},
|
|
10827
10827
|
{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nifrajs/cli",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.7.0",
|
|
4
4
|
"description": "The nifra CLI - zero-config dev/build/start for a nifra app (`nifra dev`, `nifra build`, `nifra start`).",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"bun",
|
|
@@ -41,14 +41,14 @@
|
|
|
41
41
|
"access": "public"
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@nifrajs/client": "2.
|
|
45
|
-
"@nifrajs/core": "2.
|
|
46
|
-
"@nifrajs/mcp": "2.
|
|
47
|
-
"@nifrajs/runner": "2.
|
|
48
|
-
"@nifrajs/schema": "2.
|
|
49
|
-
"@nifrajs/testing": "2.
|
|
50
|
-
"@nifrajs/web": "2.
|
|
51
|
-
"create-nifra": "2.
|
|
44
|
+
"@nifrajs/client": "2.7.0",
|
|
45
|
+
"@nifrajs/core": "2.7.0",
|
|
46
|
+
"@nifrajs/mcp": "2.7.0",
|
|
47
|
+
"@nifrajs/runner": "2.7.0",
|
|
48
|
+
"@nifrajs/schema": "2.7.0",
|
|
49
|
+
"@nifrajs/testing": "2.7.0",
|
|
50
|
+
"@nifrajs/web": "2.7.0",
|
|
51
|
+
"create-nifra": "2.7.0"
|
|
52
52
|
},
|
|
53
53
|
"repository": {
|
|
54
54
|
"type": "git",
|
package/src/cli.ts
CHANGED
|
@@ -154,7 +154,7 @@ Port: \`dev\` and \`start\` share the default ${DEFAULT_DEV_PORT}. Override with
|
|
|
154
154
|
\`PORT\` env var (\`--port\` wins over \`PORT\`, which wins over the default).`
|
|
155
155
|
|
|
156
156
|
// Kept in lockstep with packages/cli/package.json by check:publish's version-consistency gate.
|
|
157
|
-
const CLI_VERSION = "2.
|
|
157
|
+
const CLI_VERSION = "2.7.0"
|
|
158
158
|
|
|
159
159
|
// A render adapter + nifra server are opaque to the CLI (it just forwards them); cast at the seam.
|
|
160
160
|
const asAdapter = (v: unknown): RenderAdapter => v as RenderAdapter
|
package/src/mcp-http.ts
CHANGED
|
@@ -29,7 +29,7 @@ export { docsTools } from "./mcp-docs-tools.ts"
|
|
|
29
29
|
export type { TypeEntry } from "./types-search.ts"
|
|
30
30
|
|
|
31
31
|
// Kept in lockstep with packages/cli/package.json by check:publish's version-consistency gate.
|
|
32
|
-
const VERSION = "2.
|
|
32
|
+
const VERSION = "2.7.0"
|
|
33
33
|
const SERVER_INFO = { name: "nifra-docs", version: VERSION }
|
|
34
34
|
// Derive the GET/health tool list from the tools actually served, so the line can never drift from them.
|
|
35
35
|
const docsHealth = (tools: McpTool[]): string =>
|