@farm.js/auth 0.1.51-beta.3 → 0.1.61
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 +5 -1
- package/dist/internal.d.ts +0 -6
- package/dist/internal.d.ts.map +1 -1
- package/dist/internal.js +2 -15
- package/dist/runtime.d.ts +1 -12
- package/dist/runtime.d.ts.map +1 -1
- package/dist/runtime.js +8 -129
- package/package.json +11 -3
package/README.md
CHANGED
|
@@ -165,7 +165,11 @@ enable `server.trustProxy` so visitors are not all counted as the proxy's addres
|
|
|
165
165
|
|
|
166
166
|
- `@farm.js/auth/server`: the `auth.session()` and `auth.user()` helpers.
|
|
167
167
|
- `@farm.js/auth/client`: `useAuth`, `signIn`, `signUp`, `signOut`, `getSession`, and
|
|
168
|
-
`createFarmAuthClient`.
|
|
168
|
+
`createFarmAuthClient`. React Native screens (`page.native.tsx`) use the same import: Metro
|
|
169
|
+
resolves its `react-native` build, which calls the auth routes through `serverFetch` from
|
|
170
|
+
`@farm.js/native` (an optional peer). `signIn` and `signUp` go through the mobile shell's native
|
|
171
|
+
code, which keeps the session cookie in the WebView and issues the device token; social sign-in
|
|
172
|
+
rejects there for now. Web bundles do not change.
|
|
169
173
|
- `@farm.js/auth`: `resolveFarmAuthConfig` and the configuration and session types, such as
|
|
170
174
|
`FarmAuthConfig`, `FarmAuthSession`, and `FarmAuthUser`.
|
|
171
175
|
- `@farm.js/auth/internal`: loaded by Farm core and `farm auth migrate`. Applications do not
|
package/dist/internal.d.ts
CHANGED
|
@@ -15,12 +15,6 @@ interface FarmAuthIntegration {
|
|
|
15
15
|
methods: readonly ["GET", "POST"];
|
|
16
16
|
handler(request: Request): Promise<Response>;
|
|
17
17
|
}>;
|
|
18
|
-
session(request: Request): Promise<FarmAuthIntegrationSession | null>;
|
|
19
|
-
}
|
|
20
|
-
interface FarmAuthIntegrationSession {
|
|
21
|
-
id: string;
|
|
22
|
-
userId: string;
|
|
23
|
-
expiresAt: Date;
|
|
24
18
|
}
|
|
25
19
|
export declare function createFarmAuthIntegration(config: ResolvedFarmAuthConfig, options: FarmAuthIntegrationOptions): FarmAuthIntegration;
|
|
26
20
|
export declare function migrateFarmAuth(): Promise<void>;
|
package/dist/internal.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../src/internal.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../src/internal.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,YAAY,CAAC;AASzD,UAAU,0BAA0B;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,aAAa,GAAG,YAAY,CAAC;CACpC;AAED,UAAU,mBAAmB;IAC3B,QAAQ,CAAC,IAAI,EAAE,kBAAkB,CAAC;IAClC,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,WAAW,CAAC;IAClB,QAAQ,EAAE;QAAE,QAAQ,CAAC,IAAI,EAAE,mBAAmB,CAAA;KAAE,CAAC;IACjD,MAAM,EAAE,KAAK,CAAC;QACZ,IAAI,EAAE,MAAM,CAAC;QACb,OAAO,EAAE,SAAS,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;QAClC,OAAO,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;KAC9C,CAAC,CAAC;CACJ;AAED,wBAAgB,yBAAyB,CACvC,MAAM,EAAE,sBAAsB,EAC9B,OAAO,EAAE,0BAA0B,GAClC,mBAAmB,CAmBrB;AAED,wBAAsB,eAAe,IAAI,OAAO,CAAC,IAAI,CAAC,CAErD;AAED,wBAAsB,wBAAwB,IAAI,OAAO,CAAC,MAAM,CAAC,CAEhE;AAED,wBAAsB,eAAe,IAAI,OAAO,CAAC,IAAI,CAAC,CAErD"}
|
package/dist/internal.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { configureFarmAuth, disposeFarmAuth as runDispose, getFarmAuthRuntime, migrateFarmAuth as runMigration,
|
|
1
|
+
import { configureFarmAuth, disposeFarmAuth as runDispose, getFarmAuthRuntime, migrateFarmAuth as runMigration, compileFarmAuthMigration as runCompileMigration, } from "./runtime.js";
|
|
2
2
|
export function createFarmAuthIntegration(config, options) {
|
|
3
3
|
configureFarmAuth(config, options);
|
|
4
4
|
return {
|
|
@@ -12,23 +12,10 @@ export function createFarmAuthIntegration(config, options) {
|
|
|
12
12
|
methods: ["GET", "POST"],
|
|
13
13
|
async handler(request) {
|
|
14
14
|
const runtime = await getFarmAuthRuntime();
|
|
15
|
-
return runtime.handler(
|
|
15
|
+
return runtime.handler(request);
|
|
16
16
|
},
|
|
17
17
|
},
|
|
18
18
|
],
|
|
19
|
-
// Farm's session contract: who the request's cookies sign in. Mobile session tokens use it.
|
|
20
|
-
async session(request) {
|
|
21
|
-
const runtime = await getFarmAuthRuntime();
|
|
22
|
-
const result = (await runtime.api.getSession({ headers: request.headers }));
|
|
23
|
-
const session = result?.session;
|
|
24
|
-
if (!session || typeof session.id !== "string")
|
|
25
|
-
return null;
|
|
26
|
-
return {
|
|
27
|
-
id: session.id,
|
|
28
|
-
userId: String(session.userId),
|
|
29
|
-
expiresAt: new Date(session.expiresAt),
|
|
30
|
-
};
|
|
31
|
-
},
|
|
32
19
|
};
|
|
33
20
|
}
|
|
34
21
|
export async function migrateFarmAuth() {
|
package/dist/runtime.d.ts
CHANGED
|
@@ -13,13 +13,6 @@ interface BetterAuthRuntime {
|
|
|
13
13
|
}
|
|
14
14
|
export declare function configureFarmAuth(config: ResolvedFarmAuthConfig, options: FarmAuthRuntimeOptions): void;
|
|
15
15
|
export declare function getFarmAuthRuntime(): Promise<BetterAuthRuntime>;
|
|
16
|
-
/**
|
|
17
|
-
* The request Better Auth's handler sees, carrying the client address Farm
|
|
18
|
-
* resolved. Better Auth keys its sign-in rate limit on that address; left to
|
|
19
|
-
* its default it reads a client-supplied single-value x-forwarded-for, so a
|
|
20
|
-
* rotating header bypassed the limit and requests without one shared a bucket.
|
|
21
|
-
*/
|
|
22
|
-
export declare function withFarmAuthClientAddress(request: Request): Request;
|
|
23
16
|
export declare function getFarmAuthRequest(request?: Request): Request;
|
|
24
17
|
/**
|
|
25
18
|
* Close the connection opened for the runtime and drop the cached instance.
|
|
@@ -54,11 +47,7 @@ export declare function resolveFarmAuthBaseURL(mode: "development" | "production
|
|
|
54
47
|
* A production deployment is still reachable at its own deployment hostname,
|
|
55
48
|
* and previews get a fresh one per build, so both are trusted explicitly
|
|
56
49
|
* rather than leaving direct deployment-URL access broken.
|
|
57
|
-
*
|
|
58
|
-
* `farm dev` without a configured URL also trusts the origin the dev server is
|
|
59
|
-
* serving the request on, so another port, an emulator's `10.0.2.2`, or a LAN
|
|
60
|
-
* address under `--host` can sign in. See `resolveDevServerOrigin`.
|
|
61
50
|
*/
|
|
62
|
-
export declare function resolveFarmAuthTrustedOrigins(
|
|
51
|
+
export declare function resolveFarmAuthTrustedOrigins(env?: NodeJS.ProcessEnv): string[];
|
|
63
52
|
export {};
|
|
64
53
|
//# sourceMappingURL=runtime.d.ts.map
|
package/dist/runtime.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runtime.d.ts","sourceRoot":"","sources":["../src/runtime.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"runtime.d.ts","sourceRoot":"","sources":["../src/runtime.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,YAAY,CAAC;AAMzD,UAAU,sBAAsB;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,aAAa,GAAG,YAAY,CAAC;CACpC;AAED,UAAU,iBAAiB;IACzB,OAAO,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;IAC7C,GAAG,EAAE;QACH,UAAU,CAAC,KAAK,EAAE;YAAE,OAAO,EAAE,OAAO,CAAA;SAAE,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;KAC3D,CAAC;CACH;AAqBD,wBAAgB,iBAAiB,CAC/B,MAAM,EAAE,sBAAsB,EAC9B,OAAO,EAAE,sBAAsB,GAC9B,IAAI,CAeN;AAED,wBAAsB,kBAAkB,IAAI,OAAO,CAAC,iBAAiB,CAAC,CA6BrE;AAED,wBAAgB,kBAAkB,CAAC,OAAO,CAAC,EAAE,OAAO,GAAG,OAAO,CAU7D;AAED;;;;;;GAMG;AACH,wBAAsB,eAAe,IAAI,OAAO,CAAC,IAAI,CAAC,CASrD;AAED,wBAAsB,eAAe,IAAI,OAAO,CAAC,IAAI,CAAC,CAIrD;AAED;;;;GAIG;AACH,wBAAsB,wBAAwB,IAAI,OAAO,CAAC,MAAM,CAAC,CAEhE;AA4ED;;;;;;;;;;GAUG;AACH,wBAAgB,sBAAsB,CACpC,IAAI,EAAE,aAAa,GAAG,YAAY,EAClC,GAAG,GAAE,MAAM,CAAC,UAAwB,GACnC,MAAM,GAAG,SAAS,CAWpB;AAED;;;;;;GAMG;AACH,wBAAgB,6BAA6B,CAAC,GAAG,GAAE,MAAM,CAAC,UAAwB,GAAG,MAAM,EAAE,CAM5F"}
|
package/dist/runtime.js
CHANGED
|
@@ -1,17 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { mkdir, readFile, writeFile } from "node:fs/promises";
|
|
1
|
+
import { mkdir } from "node:fs/promises";
|
|
3
2
|
import { createRequire } from "node:module";
|
|
4
|
-
import { isIP } from "node:net";
|
|
5
3
|
import path from "node:path";
|
|
6
4
|
const FARM_AUTH_STATE_KEY = Symbol.for("@farm.js/auth/runtime");
|
|
7
5
|
const CURRENT_REQUEST_RESOLVER_KEY = Symbol.for("farm.currentRequestResolver");
|
|
8
6
|
const loadNodeModule = createRequire(import.meta.url);
|
|
9
|
-
/**
|
|
10
|
-
* Where Better Auth reads the caller's address from. Farm Auth sets it from the
|
|
11
|
-
* address Farm resolved for the request (the server's peer address, or the
|
|
12
|
-
* forwarded one under `server.trustProxy`) and drops any copy the client sent.
|
|
13
|
-
*/
|
|
14
|
-
const CLIENT_ADDRESS_HEADER = "x-farm-auth-client-address";
|
|
15
7
|
function getState() {
|
|
16
8
|
const runtime = globalThis;
|
|
17
9
|
runtime[FARM_AUTH_STATE_KEY] ||= {};
|
|
@@ -61,23 +53,6 @@ export async function getFarmAuthRuntime() {
|
|
|
61
53
|
}
|
|
62
54
|
return state.runtime;
|
|
63
55
|
}
|
|
64
|
-
/**
|
|
65
|
-
* The request Better Auth's handler sees, carrying the client address Farm
|
|
66
|
-
* resolved. Better Auth keys its sign-in rate limit on that address; left to
|
|
67
|
-
* its default it reads a client-supplied single-value x-forwarded-for, so a
|
|
68
|
-
* rotating header bypassed the limit and requests without one shared a bucket.
|
|
69
|
-
*/
|
|
70
|
-
export function withFarmAuthClientAddress(request) {
|
|
71
|
-
const address = request.socket
|
|
72
|
-
?.remoteAddress;
|
|
73
|
-
if (!address && !request.headers.has(CLIENT_ADDRESS_HEADER))
|
|
74
|
-
return request;
|
|
75
|
-
const headers = new Headers(request.headers);
|
|
76
|
-
headers.delete(CLIENT_ADDRESS_HEADER);
|
|
77
|
-
if (address)
|
|
78
|
-
headers.set(CLIENT_ADDRESS_HEADER, address);
|
|
79
|
-
return new Request(request, { headers });
|
|
80
|
-
}
|
|
81
56
|
export function getFarmAuthRequest(request) {
|
|
82
57
|
if (request)
|
|
83
58
|
return request;
|
|
@@ -153,9 +128,9 @@ async function createBetterAuthOptions(config, options, runtimeOptions = {}) {
|
|
|
153
128
|
return {
|
|
154
129
|
appName: config.appName || "Farm app",
|
|
155
130
|
baseURL: resolveFarmAuthBaseURL(options.mode),
|
|
156
|
-
trustedOrigins: resolveFarmAuthTrustedOrigins(
|
|
131
|
+
trustedOrigins: resolveFarmAuthTrustedOrigins(),
|
|
157
132
|
basePath: config.basePath,
|
|
158
|
-
secret: secret ||
|
|
133
|
+
secret: secret || "farm-auth-development-or-migration-secret",
|
|
159
134
|
database: await createDatabase(config, options),
|
|
160
135
|
emailAndPassword: {
|
|
161
136
|
enabled: config.emailAndPassword.enabled,
|
|
@@ -167,62 +142,8 @@ async function createBetterAuthOptions(config, options, runtimeOptions = {}) {
|
|
|
167
142
|
expiresIn: config.session.expiresIn,
|
|
168
143
|
updateAge: config.session.updateAge,
|
|
169
144
|
},
|
|
170
|
-
advanced: {
|
|
171
|
-
ipAddress: { ipAddressHeaders: [CLIENT_ADDRESS_HEADER] },
|
|
172
|
-
},
|
|
173
145
|
};
|
|
174
146
|
}
|
|
175
|
-
/** Random secrets used when a project directory cannot hold one, kept for the process. */
|
|
176
|
-
const ephemeralSecrets = new Map();
|
|
177
|
-
/**
|
|
178
|
-
* The secret used when no secret env is set: development or a migration, which never signs.
|
|
179
|
-
*
|
|
180
|
-
* A fixed fallback would let anyone who reaches a dev server (a `farm preview` URL, `--host`) forge
|
|
181
|
-
* Better Auth's signed tokens, such as email verification links. Development instead generates a
|
|
182
|
-
* random secret once per project in `.farm/auth-secret`, next to the local database, so sessions
|
|
183
|
-
* survive restarts. A production migration gets a throwaway one and writes nothing.
|
|
184
|
-
*/
|
|
185
|
-
async function resolveFallbackSecret(options) {
|
|
186
|
-
const file = path.resolve(options.root, ".farm", "auth-secret");
|
|
187
|
-
if (options.mode !== "development")
|
|
188
|
-
return getEphemeralSecret(file);
|
|
189
|
-
const existing = await readSecretFile(file);
|
|
190
|
-
if (existing)
|
|
191
|
-
return existing;
|
|
192
|
-
const generated = randomBytes(32).toString("hex");
|
|
193
|
-
try {
|
|
194
|
-
await mkdir(path.dirname(file), { recursive: true });
|
|
195
|
-
// `wx` keeps a secret another process wrote first; that one is read back below.
|
|
196
|
-
await writeFile(file, `${generated}\n`, { flag: "wx", mode: 0o600 });
|
|
197
|
-
return generated;
|
|
198
|
-
}
|
|
199
|
-
catch (error) {
|
|
200
|
-
if (error.code !== "EEXIST")
|
|
201
|
-
return getEphemeralSecret(file);
|
|
202
|
-
}
|
|
203
|
-
// Another process won the race, or the file holds no usable secret.
|
|
204
|
-
const raced = await readSecretFile(file);
|
|
205
|
-
if (raced)
|
|
206
|
-
return raced;
|
|
207
|
-
return writeFile(file, `${generated}\n`, { mode: 0o600 }).then(() => generated, () => getEphemeralSecret(file));
|
|
208
|
-
}
|
|
209
|
-
async function readSecretFile(file) {
|
|
210
|
-
try {
|
|
211
|
-
const value = (await readFile(file, "utf8")).trim();
|
|
212
|
-
return value.length >= 32 ? value : undefined;
|
|
213
|
-
}
|
|
214
|
-
catch {
|
|
215
|
-
return undefined;
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
function getEphemeralSecret(key) {
|
|
219
|
-
let secret = ephemeralSecrets.get(key);
|
|
220
|
-
if (!secret) {
|
|
221
|
-
secret = randomBytes(32).toString("hex");
|
|
222
|
-
ephemeralSecrets.set(key, secret);
|
|
223
|
-
}
|
|
224
|
-
return secret;
|
|
225
|
-
}
|
|
226
147
|
/**
|
|
227
148
|
* The origin Better Auth signs cookies and validates requests against.
|
|
228
149
|
*
|
|
@@ -235,19 +156,15 @@ function getEphemeralSecret(key) {
|
|
|
235
156
|
* so production prefers the canonical one and previews keep their own URL.
|
|
236
157
|
*/
|
|
237
158
|
export function resolveFarmAuthBaseURL(mode, env = process.env) {
|
|
238
|
-
const configured = resolveConfiguredBaseURL(env);
|
|
239
|
-
if (configured)
|
|
240
|
-
return configured;
|
|
241
|
-
return mode === "development" ? "http://localhost:3000" : undefined;
|
|
242
|
-
}
|
|
243
|
-
function resolveConfiguredBaseURL(env) {
|
|
244
159
|
const configured = env.FARM_AUTH_URL || env.BETTER_AUTH_URL;
|
|
245
160
|
if (configured)
|
|
246
161
|
return configured;
|
|
247
162
|
const vercelHost = env.VERCEL_ENV === "production"
|
|
248
163
|
? env.VERCEL_PROJECT_PRODUCTION_URL || env.VERCEL_URL
|
|
249
164
|
: env.VERCEL_URL;
|
|
250
|
-
|
|
165
|
+
if (vercelHost)
|
|
166
|
+
return toAbsoluteOrigin(vercelHost);
|
|
167
|
+
return mode === "development" ? "http://localhost:3000" : undefined;
|
|
251
168
|
}
|
|
252
169
|
/**
|
|
253
170
|
* Hosts that stay valid alongside the base URL.
|
|
@@ -255,52 +172,14 @@ function resolveConfiguredBaseURL(env) {
|
|
|
255
172
|
* A production deployment is still reachable at its own deployment hostname,
|
|
256
173
|
* and previews get a fresh one per build, so both are trusted explicitly
|
|
257
174
|
* rather than leaving direct deployment-URL access broken.
|
|
258
|
-
*
|
|
259
|
-
* `farm dev` without a configured URL also trusts the origin the dev server is
|
|
260
|
-
* serving the request on, so another port, an emulator's `10.0.2.2`, or a LAN
|
|
261
|
-
* address under `--host` can sign in. See `resolveDevServerOrigin`.
|
|
262
175
|
*/
|
|
263
|
-
export function resolveFarmAuthTrustedOrigins(
|
|
176
|
+
export function resolveFarmAuthTrustedOrigins(env = process.env) {
|
|
264
177
|
const origins = new Set();
|
|
265
178
|
for (const host of [env.VERCEL_URL, env.VERCEL_PROJECT_PRODUCTION_URL, env.VERCEL_BRANCH_URL]) {
|
|
266
179
|
if (host)
|
|
267
180
|
origins.add(toAbsoluteOrigin(host));
|
|
268
181
|
}
|
|
269
|
-
|
|
270
|
-
// A configured URL stays authoritative, in development too.
|
|
271
|
-
if (mode !== "development" || resolveConfiguredBaseURL(env))
|
|
272
|
-
return trusted;
|
|
273
|
-
return (request) => {
|
|
274
|
-
const own = request ? resolveDevServerOrigin(request) : undefined;
|
|
275
|
-
return own ? [...trusted, own] : trusted;
|
|
276
|
-
};
|
|
277
|
-
}
|
|
278
|
-
/**
|
|
279
|
-
* The dev server's own origin for this request, when it is safe to trust.
|
|
280
|
-
*
|
|
281
|
-
* In development the request URL comes from the Host the dev server accepted,
|
|
282
|
-
* so a page served by the dev server sends that same origin. Only hosts that
|
|
283
|
-
* cannot be DNS-rebound are trusted: `localhost`, `*.localhost`, and IP
|
|
284
|
-
* literals, the hosts Vite allows without `server.allowedHosts`. A rebinding
|
|
285
|
-
* page on `evil.example` that resolves to the dev server sends its own Host and
|
|
286
|
-
* Origin, which match each other but are not trusted here. A cross-site page
|
|
287
|
-
* sends an Origin that is not this request's origin, so it stays rejected.
|
|
288
|
-
*/
|
|
289
|
-
function resolveDevServerOrigin(request) {
|
|
290
|
-
let url;
|
|
291
|
-
try {
|
|
292
|
-
url = new URL(request.url);
|
|
293
|
-
}
|
|
294
|
-
catch {
|
|
295
|
-
return undefined;
|
|
296
|
-
}
|
|
297
|
-
if (url.protocol !== "http:" && url.protocol !== "https:")
|
|
298
|
-
return undefined;
|
|
299
|
-
const hostname = url.hostname.toLowerCase();
|
|
300
|
-
const trusted = hostname === "localhost" ||
|
|
301
|
-
hostname.endsWith(".localhost") ||
|
|
302
|
-
isIP(hostname.replace(/^\[|\]$/g, "")) !== 0;
|
|
303
|
-
return trusted ? url.origin : undefined;
|
|
182
|
+
return [...origins];
|
|
304
183
|
}
|
|
305
184
|
function toAbsoluteOrigin(host) {
|
|
306
185
|
return host.startsWith("http://") || host.startsWith("https://") ? host : `https://${host}`;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@farm.js/auth",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.61",
|
|
4
4
|
"description": "Farm-native authentication with email/password, server helpers, and React hooks",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -28,6 +28,7 @@
|
|
|
28
28
|
},
|
|
29
29
|
"./client": {
|
|
30
30
|
"types": "./dist/client.d.ts",
|
|
31
|
+
"react-native": "./dist/client.native.js",
|
|
31
32
|
"import": "./dist/client.js",
|
|
32
33
|
"default": "./dist/client.js"
|
|
33
34
|
},
|
|
@@ -51,10 +52,17 @@
|
|
|
51
52
|
"react": "19.2.8",
|
|
52
53
|
"typescript": "^5.3.3",
|
|
53
54
|
"vite": "8.3.4",
|
|
54
|
-
"vitest": "5.0.5"
|
|
55
|
+
"vitest": "5.0.5",
|
|
56
|
+
"@farm.js/native": "0.1.0-beta.3"
|
|
55
57
|
},
|
|
56
58
|
"peerDependencies": {
|
|
57
|
-
"react": "^18.2.0 || ^19.0.0"
|
|
59
|
+
"react": "^18.2.0 || ^19.0.0",
|
|
60
|
+
"@farm.js/native": "^0.1.0-beta.3"
|
|
61
|
+
},
|
|
62
|
+
"peerDependenciesMeta": {
|
|
63
|
+
"@farm.js/native": {
|
|
64
|
+
"optional": true
|
|
65
|
+
}
|
|
58
66
|
},
|
|
59
67
|
"optionalDependencies": {
|
|
60
68
|
"better-sqlite3": "12.8.0"
|