@sfxcode/nuxt-mongocamp-server 2.2.0 → 2.3.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/README.md +52 -1
- package/dist/module.d.mts +10 -0
- package/dist/module.json +1 -1
- package/dist/module.mjs +91 -11
- package/dist/runtime/api/.openapi-generator/FILES +18 -0
- package/dist/runtime/api/apis/CollectionApi.d.ts +124 -0
- package/dist/runtime/api/apis/CollectionApi.js +205 -0
- package/dist/runtime/api/apis/DocumentApi.d.ts +134 -0
- package/dist/runtime/api/apis/DocumentApi.js +208 -0
- package/dist/runtime/api/docs/AuditEntry.md +52 -0
- package/dist/runtime/api/docs/CollectionApi.md +269 -2
- package/dist/runtime/api/docs/CollectionDeclaration.md +52 -0
- package/dist/runtime/api/docs/CollectionDeclarationAudit.md +34 -0
- package/dist/runtime/api/docs/CollectionDeclarationOwner.md +36 -0
- package/dist/runtime/api/docs/CollectionDeclarationSoftDelete.md +36 -0
- package/dist/runtime/api/docs/CollectionDeclarationTimestamps.md +40 -0
- package/dist/runtime/api/docs/CollectionDeclarationVersioned.md +38 -0
- package/dist/runtime/api/docs/DocumentApi.md +282 -8
- package/dist/runtime/api/docs/ErrorDescription.md +4 -0
- package/dist/runtime/api/docs/SuggestedValidator.md +40 -0
- package/dist/runtime/api/docs/ValidationIssue.md +36 -0
- package/dist/runtime/api/models/AuditEntry.d.ts +88 -0
- package/dist/runtime/api/models/AuditEntry.js +56 -0
- package/dist/runtime/api/models/CollectionDeclaration.d.ts +80 -0
- package/dist/runtime/api/models/CollectionDeclaration.js +73 -0
- package/dist/runtime/api/models/CollectionDeclarationAudit.d.ts +30 -0
- package/dist/runtime/api/models/CollectionDeclarationAudit.js +26 -0
- package/dist/runtime/api/models/CollectionDeclarationOwner.d.ts +43 -0
- package/dist/runtime/api/models/CollectionDeclarationOwner.js +34 -0
- package/dist/runtime/api/models/CollectionDeclarationSoftDelete.d.ts +34 -0
- package/dist/runtime/api/models/CollectionDeclarationSoftDelete.js +28 -0
- package/dist/runtime/api/models/CollectionDeclarationTimestamps.d.ts +42 -0
- package/dist/runtime/api/models/CollectionDeclarationTimestamps.js +33 -0
- package/dist/runtime/api/models/CollectionDeclarationVersioned.d.ts +46 -0
- package/dist/runtime/api/models/CollectionDeclarationVersioned.js +36 -0
- package/dist/runtime/api/models/ErrorDescription.d.ts +11 -0
- package/dist/runtime/api/models/ErrorDescription.js +10 -2
- package/dist/runtime/api/models/SuggestedValidator.d.ts +44 -0
- package/dist/runtime/api/models/SuggestedValidator.js +35 -0
- package/dist/runtime/api/models/ValidationIssue.d.ts +34 -0
- package/dist/runtime/api/models/ValidationIssue.js +29 -0
- package/dist/runtime/api/models/index.d.ts +9 -0
- package/dist/runtime/api/models/index.js +9 -0
- package/dist/runtime/composables/mongocampApiCollection.d.ts +14 -15
- package/dist/runtime/composables/mongocampApiCollection.js +4 -1
- package/dist/runtime/composables/mongocampCollection.d.ts +106 -0
- package/dist/runtime/composables/mongocampCollection.js +200 -0
- package/dist/runtime/composables/mongocampLive.d.ts +33 -0
- package/dist/runtime/composables/mongocampLive.js +152 -0
- package/dist/runtime/composables/mongocampSearch.d.ts +12 -9
- package/dist/runtime/server/mongocamp/plugin.d.ts +2 -2
- package/dist/runtime/server/mongocamp/plugin.js +10 -1
- package/dist/runtime/types/collections.d.ts +20 -0
- package/dist/runtime/types/collections.js +0 -0
- package/dist/runtime/utils/sse.d.ts +10 -0
- package/dist/runtime/utils/sse.js +33 -0
- package/dist/runtime/utils/toMongocampError.d.ts +7 -0
- package/dist/runtime/utils/toMongocampError.js +18 -1
- package/dist/types.d.mts +6 -0
- package/package.json +4 -3
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
import { getCurrentInstance, getCurrentScope, onMounted, onScopeDispose, ref } from "vue";
|
|
2
|
+
import { documentId, fromExtendedJson } from "../utils/extendedJson.js";
|
|
3
|
+
import { createSseParser } from "../utils/sse.js";
|
|
4
|
+
import { useMongocampCollection } from "./mongocampCollection.js";
|
|
5
|
+
import { useMongocampStorage } from "./mongocampStorage.js";
|
|
6
|
+
import { useMongocampUrl } from "./mongocampUrl.js";
|
|
7
|
+
const MaxBackoff = 3e4;
|
|
8
|
+
const RefetchDebounce = 200;
|
|
9
|
+
let pollingExplained = false;
|
|
10
|
+
export function useMongocampLive(name, options = {}) {
|
|
11
|
+
const collection = useMongocampCollection(name);
|
|
12
|
+
const url = useMongocampUrl();
|
|
13
|
+
const session = useMongocampStorage();
|
|
14
|
+
const mode = options.mode ?? (options.sort !== void 0 || options.page !== void 0 ? "refetch" : "patch");
|
|
15
|
+
const documents = ref([]);
|
|
16
|
+
const status = ref("idle");
|
|
17
|
+
const error = ref(null);
|
|
18
|
+
let abort;
|
|
19
|
+
let reconnect;
|
|
20
|
+
let poll;
|
|
21
|
+
let debounce;
|
|
22
|
+
let lastEventId;
|
|
23
|
+
let backoff = 1e3;
|
|
24
|
+
let stopped = true;
|
|
25
|
+
const reload = async () => {
|
|
26
|
+
try {
|
|
27
|
+
documents.value = await collection.find(options);
|
|
28
|
+
error.value = null;
|
|
29
|
+
} catch (caught) {
|
|
30
|
+
error.value = caught;
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
const apply = (event, data) => {
|
|
34
|
+
if (event === "reset") {
|
|
35
|
+
void reload();
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
if (mode === "refetch") {
|
|
39
|
+
clearTimeout(debounce);
|
|
40
|
+
debounce = setTimeout(() => void reload(), RefetchDebounce);
|
|
41
|
+
return;
|
|
42
|
+
}
|
|
43
|
+
const id = documentId(fromExtendedJson({ _id: data.id }));
|
|
44
|
+
const others = documents.value.filter((document) => documentId(document) !== id);
|
|
45
|
+
if (event === "remove") {
|
|
46
|
+
documents.value = others;
|
|
47
|
+
} else if (event === "upsert" && data.document !== void 0) {
|
|
48
|
+
const document = fromExtendedJson(data.document);
|
|
49
|
+
const index = documents.value.findIndex((entry) => documentId(entry) === id);
|
|
50
|
+
documents.value = index < 0 ? [...documents.value, document] : documents.value.map((entry, position) => position === index ? document : entry);
|
|
51
|
+
}
|
|
52
|
+
};
|
|
53
|
+
const startPolling = () => {
|
|
54
|
+
status.value = "polling";
|
|
55
|
+
if (!pollingExplained) {
|
|
56
|
+
pollingExplained = true;
|
|
57
|
+
console.info("[mongocamp] live updates need a replica set (change streams); the list is loaded every few seconds instead");
|
|
58
|
+
}
|
|
59
|
+
clearInterval(poll);
|
|
60
|
+
poll = setInterval(() => void reload(), options.pollInterval ?? 5e3);
|
|
61
|
+
};
|
|
62
|
+
const connect = async () => {
|
|
63
|
+
if (stopped) {
|
|
64
|
+
return;
|
|
65
|
+
}
|
|
66
|
+
status.value = "connecting";
|
|
67
|
+
abort = new AbortController();
|
|
68
|
+
const query = new URLSearchParams();
|
|
69
|
+
if (options.filter !== void 0 && options.filter !== "") {
|
|
70
|
+
query.set("filter", options.filter);
|
|
71
|
+
}
|
|
72
|
+
if (options.filterCaseInsensitive) {
|
|
73
|
+
query.set("filterCaseInsensitive", "true");
|
|
74
|
+
}
|
|
75
|
+
const headers = { accept: "text/event-stream" };
|
|
76
|
+
if (session.value.token) {
|
|
77
|
+
headers.authorization = `Bearer ${session.value.token}`;
|
|
78
|
+
}
|
|
79
|
+
if (lastEventId !== void 0) {
|
|
80
|
+
headers["last-event-id"] = lastEventId;
|
|
81
|
+
}
|
|
82
|
+
try {
|
|
83
|
+
const search = query.toString();
|
|
84
|
+
const response = await fetch(`${url}/mongodb/collections/${encodeURIComponent(name)}/documents/watch${search === "" ? "" : `?${search}`}`, { headers, signal: abort.signal });
|
|
85
|
+
if (response.status === 501) {
|
|
86
|
+
startPolling();
|
|
87
|
+
return;
|
|
88
|
+
}
|
|
89
|
+
if (!response.ok || response.body === null) {
|
|
90
|
+
throw Object.assign(new Error(response.headers.get("x-error-message") ?? `live updates failed with status ${response.status}`), { status: response.status });
|
|
91
|
+
}
|
|
92
|
+
status.value = "live";
|
|
93
|
+
backoff = 1e3;
|
|
94
|
+
const parse = createSseParser((message) => {
|
|
95
|
+
if (message.id !== void 0) {
|
|
96
|
+
lastEventId = message.id;
|
|
97
|
+
}
|
|
98
|
+
apply(message.event, message.data === "" ? {} : JSON.parse(message.data));
|
|
99
|
+
});
|
|
100
|
+
const reader = response.body.pipeThrough(new TextDecoderStream()).getReader();
|
|
101
|
+
for (; ; ) {
|
|
102
|
+
const { value, done } = await reader.read();
|
|
103
|
+
if (done) {
|
|
104
|
+
break;
|
|
105
|
+
}
|
|
106
|
+
parse(value);
|
|
107
|
+
}
|
|
108
|
+
} catch (caught) {
|
|
109
|
+
if (stopped) {
|
|
110
|
+
return;
|
|
111
|
+
}
|
|
112
|
+
const failure = caught;
|
|
113
|
+
if (failure.status === 401 || failure.status === 403) {
|
|
114
|
+
error.value = failure;
|
|
115
|
+
status.value = "error";
|
|
116
|
+
return;
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
if (!stopped) {
|
|
120
|
+
status.value = "connecting";
|
|
121
|
+
reconnect = setTimeout(() => void connect(), backoff);
|
|
122
|
+
backoff = Math.min(backoff * 2, MaxBackoff);
|
|
123
|
+
}
|
|
124
|
+
};
|
|
125
|
+
const start = async () => {
|
|
126
|
+
if (!stopped) {
|
|
127
|
+
return;
|
|
128
|
+
}
|
|
129
|
+
stopped = false;
|
|
130
|
+
await reload();
|
|
131
|
+
void connect();
|
|
132
|
+
};
|
|
133
|
+
const stop = () => {
|
|
134
|
+
stopped = true;
|
|
135
|
+
abort?.abort();
|
|
136
|
+
clearTimeout(reconnect);
|
|
137
|
+
clearTimeout(debounce);
|
|
138
|
+
clearInterval(poll);
|
|
139
|
+
status.value = "stopped";
|
|
140
|
+
};
|
|
141
|
+
if (options.immediate !== false) {
|
|
142
|
+
if (getCurrentInstance() !== null) {
|
|
143
|
+
onMounted(() => void start());
|
|
144
|
+
} else if (import.meta.client) {
|
|
145
|
+
void start();
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
if (getCurrentScope() !== void 0) {
|
|
149
|
+
onScopeDispose(stop);
|
|
150
|
+
}
|
|
151
|
+
return { documents, status, error, start, stop, reload };
|
|
152
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Ref } from 'vue';
|
|
1
2
|
import type { FindRequest, MongoFindRequest } from '../api/index.js';
|
|
2
3
|
import type { FilterFieldValue } from '../utils/buildFieldFilterExpression.js';
|
|
3
4
|
export declare function useMongocampSearch(): {
|
|
@@ -21,16 +22,18 @@ export interface PaginatedFindOptions {
|
|
|
21
22
|
/** Wildcards of the filter ignore the case (server 2.0.0 matches them case-sensitively by default). */
|
|
22
23
|
filterCaseInsensitive?: boolean;
|
|
23
24
|
}
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
25
|
+
/**
|
|
26
|
+
* The pages of a find; `T` types the documents as the server sends them (default as before). Typed and decoded documents:
|
|
27
|
+
* `useMongocampCollection(name).paginated()` (2.3.0).
|
|
28
|
+
*/
|
|
29
|
+
export declare function usePaginatedFind<T = {
|
|
30
|
+
[key: string]: string;
|
|
31
|
+
}>(collectionName: string, options?: PaginatedFindOptions): {
|
|
32
|
+
documents: Ref<T[], T[]>;
|
|
33
|
+
page: Ref<number, number>;
|
|
31
34
|
rowsPerPage: any;
|
|
32
|
-
pending:
|
|
33
|
-
error:
|
|
35
|
+
pending: Ref<boolean, boolean>;
|
|
36
|
+
error: Ref<unknown, unknown>;
|
|
34
37
|
load: () => Promise<void>;
|
|
35
38
|
nextPage: () => Promise<void>;
|
|
36
39
|
previousPage: () => Promise<void>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* The Nitro plugin of the embedded server: switches on the features of the module options (`server.requestLogging`, `server.metrics`)
|
|
3
|
-
* when the server is ready, and closes it with Nitro. An application adds its own features and listeners the same way, in its own Nitro
|
|
2
|
+
* The Nitro plugin of the embedded server: switches on the features of the module options (`server.requestLogging`, `server.metrics`) and
|
|
3
|
+
* the declared collections of `server/mongocamp/` when the server is ready, and closes it with Nitro. An application adds its own features and listeners the same way, in its own Nitro
|
|
4
4
|
* plugin on the hooks `mongocamp:ready` and `mongocamp:<event>`.
|
|
5
5
|
*/
|
|
6
6
|
declare const _default: import("nitro/types").NitroAppPlugin;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { metrics, requestLogging } from "@sfxcode/mongocamp-server-core";
|
|
1
|
+
import { collections, metrics, requestLogging } from "@sfxcode/mongocamp-server-core";
|
|
2
|
+
import { declarations } from "#mongocamp/collections";
|
|
2
3
|
import { definePlugin } from "nitro";
|
|
3
4
|
import { useRuntimeConfig } from "nitro/runtime-config";
|
|
4
5
|
import { closeMongocampCore } from "./core.js";
|
|
@@ -11,6 +12,14 @@ export default definePlugin((nitroApp) => {
|
|
|
11
12
|
if (settings.metrics) {
|
|
12
13
|
await server.use(metrics());
|
|
13
14
|
}
|
|
15
|
+
if (declarations.length > 0) {
|
|
16
|
+
for (const { key, source, definition } of declarations) {
|
|
17
|
+
if (definition.name !== key) {
|
|
18
|
+
server.context.logger.warn(`[mongocamp] ${source} declares the collection ${definition.name}: the types of the client know it as ${key}, name the file ${definition.name}.ts`);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
await server.use(collections(declarations.map(({ source, definition }) => ({ ...definition, source }))));
|
|
22
|
+
}
|
|
14
23
|
});
|
|
15
24
|
nitroApp.hooks?.hook("close", async () => {
|
|
16
25
|
await closeMongocampCore();
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The documents of the declared collections by name (2.3.0). Empty here; the module adds the declarations of `server/mongocamp/*.ts`
|
|
3
|
+
* (`.nuxt/types/mongocamp-collections.d.ts`), an application without the module's scan (external server) can add its own:
|
|
4
|
+
*
|
|
5
|
+
* declare global { interface MongocampCollections { orders: Order } }
|
|
6
|
+
*/
|
|
7
|
+
declare global {
|
|
8
|
+
/** The documents as they are stored (the output of the schema). */
|
|
9
|
+
interface MongocampCollections {
|
|
10
|
+
}
|
|
11
|
+
/** The documents as they are written (the input of the schema: fields with a default are optional); falls back to the stored type. */
|
|
12
|
+
interface MongocampCollectionInputs {
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
/** The names of the declared collections. */
|
|
16
|
+
export type MongocampCollectionName = keyof MongocampCollections & string;
|
|
17
|
+
/** The stored document type of a declared collection. */
|
|
18
|
+
export type MongocampDocument<N extends MongocampCollectionName> = MongocampCollections[N];
|
|
19
|
+
/** The written document type of a declared collection. */
|
|
20
|
+
export type MongocampDocumentInput<N extends MongocampCollectionName> = N extends keyof MongocampCollectionInputs ? MongocampCollectionInputs[N] : MongocampCollections[N];
|
|
File without changes
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A parser of Server-Sent Events for a stream read with `fetch` (2.4.0, live updates): `EventSource` cannot send the bearer token of the
|
|
3
|
+
* session. Feed it the decoded text as it arrives; it calls `onEvent` for every complete event (comments are skipped).
|
|
4
|
+
*/
|
|
5
|
+
export interface SseEvent {
|
|
6
|
+
id?: string;
|
|
7
|
+
event: string;
|
|
8
|
+
data: string;
|
|
9
|
+
}
|
|
10
|
+
export declare function createSseParser(onEvent: (event: SseEvent) => void): (chunk: string) => void;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export function createSseParser(onEvent) {
|
|
2
|
+
let buffer = "";
|
|
3
|
+
return (chunk) => {
|
|
4
|
+
buffer += chunk.replace(/\r\n?/g, "\n");
|
|
5
|
+
let end = buffer.indexOf("\n\n");
|
|
6
|
+
while (end >= 0) {
|
|
7
|
+
const block = buffer.slice(0, end);
|
|
8
|
+
buffer = buffer.slice(end + 2);
|
|
9
|
+
let id;
|
|
10
|
+
let event = "message";
|
|
11
|
+
const data = [];
|
|
12
|
+
for (const line of block.split("\n")) {
|
|
13
|
+
if (line === "" || line.startsWith(":")) {
|
|
14
|
+
continue;
|
|
15
|
+
}
|
|
16
|
+
const colon = line.indexOf(":");
|
|
17
|
+
const field = colon < 0 ? line : line.slice(0, colon);
|
|
18
|
+
const value = colon < 0 ? "" : line.slice(colon + 1).replace(/^ /, "");
|
|
19
|
+
if (field === "id") {
|
|
20
|
+
id = value;
|
|
21
|
+
} else if (field === "event") {
|
|
22
|
+
event = value;
|
|
23
|
+
} else if (field === "data") {
|
|
24
|
+
data.push(value);
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
if (data.length > 0 || event !== "message") {
|
|
28
|
+
onEvent({ ...id !== void 0 ? { id } : {}, event, data: data.join("\n") });
|
|
29
|
+
}
|
|
30
|
+
end = buffer.indexOf("\n\n");
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
}
|
|
@@ -1,7 +1,14 @@
|
|
|
1
|
+
import type { ValidationIssue } from '../api/index.js';
|
|
1
2
|
export interface MongocampError {
|
|
2
3
|
status?: number;
|
|
3
4
|
message: string;
|
|
4
5
|
additionalInfo?: string;
|
|
6
|
+
/** The fields of a document that is not valid (400 of a schema, a before-hook or the validator of the collection). */
|
|
7
|
+
issues?: ValidationIssue[];
|
|
8
|
+
/** The error code of the server (`x-error-code`, e.g. 4092 for a version conflict). */
|
|
9
|
+
code?: number;
|
|
10
|
+
/** The stored document of a version conflict (409, code 4092), as the server sends it (Extended JSON). */
|
|
11
|
+
current?: Record<string, unknown>;
|
|
5
12
|
cause: unknown;
|
|
6
13
|
}
|
|
7
14
|
export declare function toMongocampError(error: unknown): Promise<MongocampError>;
|
|
@@ -4,14 +4,31 @@ export async function toMongocampError(error) {
|
|
|
4
4
|
const status = error.response.status;
|
|
5
5
|
let message = `Request failed with status ${status}`;
|
|
6
6
|
let additionalInfo;
|
|
7
|
+
let issues;
|
|
8
|
+
let code;
|
|
9
|
+
let current;
|
|
7
10
|
try {
|
|
8
11
|
const body = await error.response.clone().json();
|
|
9
12
|
if (body?.msg)
|
|
10
13
|
message = body.msg;
|
|
11
14
|
additionalInfo = body?.additionalInfo;
|
|
15
|
+
if (Array.isArray(body?.issues))
|
|
16
|
+
issues = body.issues;
|
|
17
|
+
if (typeof body?.code === "number")
|
|
18
|
+
code = body.code;
|
|
19
|
+
if (body?.current && typeof body.current === "object")
|
|
20
|
+
current = body.current;
|
|
12
21
|
} catch {
|
|
13
22
|
}
|
|
14
|
-
return {
|
|
23
|
+
return {
|
|
24
|
+
status,
|
|
25
|
+
message,
|
|
26
|
+
additionalInfo,
|
|
27
|
+
...issues ? { issues } : {},
|
|
28
|
+
...code !== void 0 ? { code } : {},
|
|
29
|
+
...current ? { current } : {},
|
|
30
|
+
cause: error
|
|
31
|
+
};
|
|
15
32
|
}
|
|
16
33
|
if (error instanceof Error)
|
|
17
34
|
return { message: error.message, cause: error };
|
package/dist/types.d.mts
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
export { type AuditEntry, type CollectionFindOptions, type CollectionPage, type DocumentIdentity, type MongocampRequestError, type PaginatedCollection, type TypedCollection } from '../dist/runtime/composables/mongocampCollection.js'
|
|
2
|
+
|
|
3
|
+
export { type MongocampCollectionName, type MongocampDocument, type MongocampDocumentInput } from '../dist/runtime/types/collections.js'
|
|
4
|
+
|
|
5
|
+
export { type LiveOptions, type LiveState, type LiveStatus } from '../dist/runtime/composables/mongocampLive.js'
|
|
6
|
+
|
|
1
7
|
export { default } from './module.mjs'
|
|
2
8
|
|
|
3
9
|
export { type ModuleOptions, type ServerOptions } from './module.mjs'
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sfxcode/nuxt-mongocamp-server",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.3.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
31
|
"@nuxt/kit": "^4.7.0",
|
|
32
|
-
"@sfxcode/mongocamp-server-core": "2.
|
|
32
|
+
"@sfxcode/mongocamp-server-core": "2.3.0",
|
|
33
33
|
"@vueuse/nuxt": "^15.1.0",
|
|
34
34
|
"bson": "^7.3.4",
|
|
35
35
|
"consola": "^3.4.2",
|
|
@@ -53,7 +53,8 @@
|
|
|
53
53
|
"nuxt": "^4.7.0",
|
|
54
54
|
"srvx": "1.0.8",
|
|
55
55
|
"typescript": "6.0.3",
|
|
56
|
-
"vitest": "^5.1.2"
|
|
56
|
+
"vitest": "^5.1.2",
|
|
57
|
+
"zod": "^4.6.7"
|
|
57
58
|
},
|
|
58
59
|
"peerDependencies": {
|
|
59
60
|
"nitro": ">=3.0.261103-rc",
|