better-call 1.0.0-beta.4 → 1.0.0-beta.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/dist/index.d.cts CHANGED
@@ -1,4 +1,4 @@
1
- export { A as APIError, k as CookieOptions, C as CookiePrefixOptions, b as Endpoint, a as EndpointContext, E as EndpointOptions, H as HTTPMethod, t as InferBody, I as InferBodyInput, B as InferHeaders, D as InferHeadersInput, x as InferInputMethod, w as InferMethod, G as InferMiddlewareBody, J as InferMiddlewareQuery, y as InferParam, v as InferQuery, u as InferQueryInput, z as InferRequest, F as InferUse, K as InputContext, r as Method, h as Middleware, e as MiddlewareContext, g as MiddlewareInputContext, M as MiddlewareOptions, d as MiddlewareResponse, n as OpenAPIParameter, O as OpenAPISchemaType, P as Path, j as Router, R as RouterConfig, S as Status, _ as _statusCode, c as createEndpoint, L as createInternalContext, f as createMiddleware, i as createRouter, o as generator, l as getCookieKey, q as getHTML, p as parseCookies, s as serializeCookie, m as serializeSignedCookie } from './router-CyNMWgsC.cjs';
1
+ export { A as APIError, k as CookieOptions, C as CookiePrefixOptions, b as Endpoint, a as EndpointContext, E as EndpointOptions, H as HTTPMethod, T as HasRequiredKeys, t as InferBody, I as InferBodyInput, B as InferHeaders, D as InferHeadersInput, x as InferInputMethod, w as InferMethod, G as InferMiddlewareBody, J as InferMiddlewareQuery, y as InferParam, Y as InferParamPath, Z as InferParamWildCard, v as InferQuery, u as InferQueryInput, z as InferRequest, F as InferUse, N as Input, K as InputContext, V as IsEmptyObject, X as MergeObject, r as Method, h as Middleware, e as MiddlewareContext, g as MiddlewareInputContext, M as MiddlewareOptions, d as MiddlewareResponse, n as OpenAPIParameter, O as OpenAPISchemaType, P as Path, U as Prettify, Q as RequiredKeysOf, j as Router, R as RouterConfig, $ as StandardSchemaV1, S as Status, W as UnionToIntersection, _ as _statusCode, c as createEndpoint, L as createInternalContext, f as createMiddleware, i as createRouter, o as generator, l as getCookieKey, q as getHTML, p as parseCookies, s as serializeCookie, m as serializeSignedCookie } from './router-G7pIJBUB.cjs';
2
2
 
3
3
  declare function toResponse(data?: any, init?: ResponseInit): Response;
4
4
 
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export { A as APIError, k as CookieOptions, C as CookiePrefixOptions, b as Endpoint, a as EndpointContext, E as EndpointOptions, H as HTTPMethod, t as InferBody, I as InferBodyInput, B as InferHeaders, D as InferHeadersInput, x as InferInputMethod, w as InferMethod, G as InferMiddlewareBody, J as InferMiddlewareQuery, y as InferParam, v as InferQuery, u as InferQueryInput, z as InferRequest, F as InferUse, K as InputContext, r as Method, h as Middleware, e as MiddlewareContext, g as MiddlewareInputContext, M as MiddlewareOptions, d as MiddlewareResponse, n as OpenAPIParameter, O as OpenAPISchemaType, P as Path, j as Router, R as RouterConfig, S as Status, _ as _statusCode, c as createEndpoint, L as createInternalContext, f as createMiddleware, i as createRouter, o as generator, l as getCookieKey, q as getHTML, p as parseCookies, s as serializeCookie, m as serializeSignedCookie } from './router-CyNMWgsC.js';
1
+ export { A as APIError, k as CookieOptions, C as CookiePrefixOptions, b as Endpoint, a as EndpointContext, E as EndpointOptions, H as HTTPMethod, T as HasRequiredKeys, t as InferBody, I as InferBodyInput, B as InferHeaders, D as InferHeadersInput, x as InferInputMethod, w as InferMethod, G as InferMiddlewareBody, J as InferMiddlewareQuery, y as InferParam, Y as InferParamPath, Z as InferParamWildCard, v as InferQuery, u as InferQueryInput, z as InferRequest, F as InferUse, N as Input, K as InputContext, V as IsEmptyObject, X as MergeObject, r as Method, h as Middleware, e as MiddlewareContext, g as MiddlewareInputContext, M as MiddlewareOptions, d as MiddlewareResponse, n as OpenAPIParameter, O as OpenAPISchemaType, P as Path, U as Prettify, Q as RequiredKeysOf, j as Router, R as RouterConfig, $ as StandardSchemaV1, S as Status, W as UnionToIntersection, _ as _statusCode, c as createEndpoint, L as createInternalContext, f as createMiddleware, i as createRouter, o as generator, l as getCookieKey, q as getHTML, p as parseCookies, s as serializeCookie, m as serializeSignedCookie } from './router-G7pIJBUB.js';
2
2
 
3
3
  declare function toResponse(data?: any, init?: ResponseInit): Response;
4
4
 
package/dist/node.d.cts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { IncomingMessage, ServerResponse } from 'node:http';
2
- import { j as Router } from './router-CyNMWgsC.cjs';
2
+ import { j as Router } from './router-G7pIJBUB.cjs';
3
3
 
4
4
  declare function getRequest({ request, base, bodySizeLimit, }: {
5
5
  base: string;
package/dist/node.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { IncomingMessage, ServerResponse } from 'node:http';
2
- import { j as Router } from './router-CyNMWgsC.js';
2
+ import { j as Router } from './router-G7pIJBUB.js';
3
3
 
4
4
  declare function getRequest({ request, base, bodySizeLimit, }: {
5
5
  base: string;
@@ -82,6 +82,7 @@ type Prettify<T> = {
82
82
  } & {};
83
83
  type IsEmptyObject<T> = keyof T extends never ? true : false;
84
84
  type UnionToIntersection<Union> = (Union extends unknown ? (distributedUnion: Union) => void : never) extends (mergedIntersection: infer Intersection) => void ? Intersection & Union : never;
85
+ type MergeObject<T extends Record<string, any> | never, S extends Record<string, any> | never> = T extends never ? S : S extends never ? T : T & S;
85
86
  type InferParamPath<Path> = Path extends `${infer _Start}:${infer Param}/${infer Rest}` ? {
86
87
  [K in Param | keyof InferParamPath<Rest>]: string;
87
88
  } : Path extends `${infer _Start}:${infer Param}` ? {
@@ -1260,4 +1261,4 @@ declare const createRouter: <E extends Record<string, Endpoint>, Config extends
1260
1261
  };
1261
1262
  type Router = ReturnType<typeof createRouter>;
1262
1263
 
1263
- export { APIError as A, type InferHeaders as B, type CookiePrefixOptions as C, type InferHeadersInput as D, type EndpointOptions as E, type InferUse as F, type InferMiddlewareBody as G, type HTTPMethod as H, type InferBodyInput as I, type InferMiddlewareQuery as J, type InputContext as K, createInternalContext as L, type MiddlewareOptions as M, type HasRequiredKeys as N, type OpenAPISchemaType as O, type Path as P, type RouterConfig as R, type Status as S, type UnionToIntersection as U, _statusCode as _, type EndpointContext as a, type Endpoint as b, createEndpoint as c, type MiddlewareResponse as d, type MiddlewareContext as e, createMiddleware as f, type MiddlewareInputContext as g, type Middleware as h, createRouter as i, type Router as j, type CookieOptions as k, getCookieKey as l, serializeSignedCookie as m, type OpenAPIParameter as n, generator as o, parseCookies as p, getHTML as q, type Method as r, serializeCookie as s, type InferBody as t, type InferQueryInput as u, type InferQuery as v, type InferMethod as w, type InferInputMethod as x, type InferParam as y, type InferRequest as z };
1264
+ export { StandardSchemaV1 as $, APIError as A, type InferHeaders as B, type CookiePrefixOptions as C, type InferHeadersInput as D, type EndpointOptions as E, type InferUse as F, type InferMiddlewareBody as G, type HTTPMethod as H, type InferBodyInput as I, type InferMiddlewareQuery as J, type InputContext as K, createInternalContext as L, type MiddlewareOptions as M, type Input as N, type OpenAPISchemaType as O, type Path as P, type RequiredKeysOf as Q, type RouterConfig as R, type Status as S, type HasRequiredKeys as T, type Prettify as U, type IsEmptyObject as V, type UnionToIntersection as W, type MergeObject as X, type InferParamPath as Y, type InferParamWildCard as Z, _statusCode as _, type EndpointContext as a, type Endpoint as b, createEndpoint as c, type MiddlewareResponse as d, type MiddlewareContext as e, createMiddleware as f, type MiddlewareInputContext as g, type Middleware as h, createRouter as i, type Router as j, type CookieOptions as k, getCookieKey as l, serializeSignedCookie as m, type OpenAPIParameter as n, generator as o, parseCookies as p, getHTML as q, type Method as r, serializeCookie as s, type InferBody as t, type InferQueryInput as u, type InferQuery as v, type InferMethod as w, type InferInputMethod as x, type InferParam as y, type InferRequest as z };
@@ -82,6 +82,7 @@ type Prettify<T> = {
82
82
  } & {};
83
83
  type IsEmptyObject<T> = keyof T extends never ? true : false;
84
84
  type UnionToIntersection<Union> = (Union extends unknown ? (distributedUnion: Union) => void : never) extends (mergedIntersection: infer Intersection) => void ? Intersection & Union : never;
85
+ type MergeObject<T extends Record<string, any> | never, S extends Record<string, any> | never> = T extends never ? S : S extends never ? T : T & S;
85
86
  type InferParamPath<Path> = Path extends `${infer _Start}:${infer Param}/${infer Rest}` ? {
86
87
  [K in Param | keyof InferParamPath<Rest>]: string;
87
88
  } : Path extends `${infer _Start}:${infer Param}` ? {
@@ -1260,4 +1261,4 @@ declare const createRouter: <E extends Record<string, Endpoint>, Config extends
1260
1261
  };
1261
1262
  type Router = ReturnType<typeof createRouter>;
1262
1263
 
1263
- export { APIError as A, type InferHeaders as B, type CookiePrefixOptions as C, type InferHeadersInput as D, type EndpointOptions as E, type InferUse as F, type InferMiddlewareBody as G, type HTTPMethod as H, type InferBodyInput as I, type InferMiddlewareQuery as J, type InputContext as K, createInternalContext as L, type MiddlewareOptions as M, type HasRequiredKeys as N, type OpenAPISchemaType as O, type Path as P, type RouterConfig as R, type Status as S, type UnionToIntersection as U, _statusCode as _, type EndpointContext as a, type Endpoint as b, createEndpoint as c, type MiddlewareResponse as d, type MiddlewareContext as e, createMiddleware as f, type MiddlewareInputContext as g, type Middleware as h, createRouter as i, type Router as j, type CookieOptions as k, getCookieKey as l, serializeSignedCookie as m, type OpenAPIParameter as n, generator as o, parseCookies as p, getHTML as q, type Method as r, serializeCookie as s, type InferBody as t, type InferQueryInput as u, type InferQuery as v, type InferMethod as w, type InferInputMethod as x, type InferParam as y, type InferRequest as z };
1264
+ export { StandardSchemaV1 as $, APIError as A, type InferHeaders as B, type CookiePrefixOptions as C, type InferHeadersInput as D, type EndpointOptions as E, type InferUse as F, type InferMiddlewareBody as G, type HTTPMethod as H, type InferBodyInput as I, type InferMiddlewareQuery as J, type InputContext as K, createInternalContext as L, type MiddlewareOptions as M, type Input as N, type OpenAPISchemaType as O, type Path as P, type RequiredKeysOf as Q, type RouterConfig as R, type Status as S, type HasRequiredKeys as T, type Prettify as U, type IsEmptyObject as V, type UnionToIntersection as W, type MergeObject as X, type InferParamPath as Y, type InferParamWildCard as Z, _statusCode as _, type EndpointContext as a, type Endpoint as b, createEndpoint as c, type MiddlewareResponse as d, type MiddlewareContext as e, createMiddleware as f, type MiddlewareInputContext as g, type Middleware as h, createRouter as i, type Router as j, type CookieOptions as k, getCookieKey as l, serializeSignedCookie as m, type OpenAPIParameter as n, generator as o, parseCookies as p, getHTML as q, type Method as r, serializeCookie as s, type InferBody as t, type InferQueryInput as u, type InferQuery as v, type InferMethod as w, type InferInputMethod as x, type InferParam as y, type InferRequest as z };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "better-call",
3
- "version": "1.0.0-beta.4",
3
+ "version": "1.0.0-beta.5",
4
4
  "type": "module",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.js",