Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bridge

Package Overview
Dependencies
Maintainers
2
Versions
99
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bridge - npm Package Compare versions

Comparing version 2.0.59 to 2.0.60

dist/test/index.d.ts

15

dist/source/core/types.d.ts

@@ -1,2 +0,2 @@

import { KeysWithValNotEmptyObject, MidsReturnsIntersection, MidsParams } from '../utilities';
import { KeysWithValNotEmptyObject, MidsReturnsIntersection, MidsParams, ExcludeNeverKeysObj, Pretify } from '../utilities';
import { DataParser, BridgeHandler, InferDataParser, FilesConfig } from './handlers';

@@ -12,3 +12,14 @@ import { FormidableFile } from '../utilities';

}
export type CreateHandler = <Resolve extends (p: {
export type CreateHandler = <Resolve extends (p: Pretify<ExcludeNeverKeysObj<{
middlewares: MidsReturnsIntersection<Middelwares> extends never ? {} : MidsReturnsIntersection<Middelwares>;
body: (InferDataParser<Body> extends never ? {} : InferDataParser<Body>) & (MidsParams<Middelwares>['body'] extends never ? {} : MidsParams<Middelwares>['body']);
query: (InferDataParser<Query> extends never ? {} : InferDataParser<Query>) & (MidsParams<Middelwares>['query'] extends never ? {} : MidsParams<Middelwares>['query']);
headers: (InferDataParser<Headers> extends never ? {} : InferDataParser<Headers>) & (MidsParams<Middelwares>['headers'] extends never ? {} : MidsParams<Middelwares>['headers']);
files: Files extends ['BridgeFilesDoNotExists'] ? {} : Files extends 'any' ? {
[key: string]: FormidableFile;
} : {
[key in Files[number]]: FormidableFile;
};
}>>) => Res, Res, Body extends DataParser<Record<any, any>> = never, Query extends DataParser<Record<string, any>> = never, Headers extends DataParser<Record<string, any>> = never, Files extends FilesConfig = ['BridgeFilesDoNotExists'], Middelwares extends ReadonlyArray<BridgeHandler> = never>(p: BridgeParams<Resolve, Middelwares, Body, Query, Headers, Files>) => BridgeHandler<Resolve, Middelwares>;
export type CreateHandlerOld = <Resolve extends (p: {
[key in KeysWithValNotEmptyObject<{

@@ -15,0 +26,0 @@ middlewares: MidsReturnsIntersection<Middelwares> extends never ? {} : MidsReturnsIntersection<Middelwares>;

import { BridgeHandler } from '../core/handlers';
export type Pretify<T> = {
[K in keyof T]: T[K];
} & {};
export type UnionToIntersection<U> = (U extends any ? (k: U) => void : never) extends (k: infer I) => void ? I : never;

@@ -9,2 +12,5 @@ export type KeysWithValNotNever<T> = keyof {

};
export type ExcludeNeverKeysObj<T> = {
[key in KeysWithValNotEmptyObject<T> & keyof T]: T[key];
};
export type KeysWithValNotEmptyObject<T> = keyof {

@@ -11,0 +17,0 @@ [P in keyof T as keyof T[P] extends never ? never : P]: P;

5

package.json
{
"name": "bridge",
"version": "2.0.59",
"version": "2.0.60",
"description": "Bridge is a Typescript Node.js framework that provides an easy and scalable way to create REST APIs while generating the client code.",

@@ -41,4 +41,5 @@ "author": "Bridge Team <support@bridge.codes>",

"ts-node": "^10.9.1",
"typescript": "^5.1.3"
"typescript": "^5.1.3",
"zod": "^3.21.4"
}
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc