tidewave 0.1.0 → 0.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 +91 -1
- package/dist/cli/index.d.ts +2 -0
- package/dist/cli/index.js +14072 -955
- package/dist/core.d.ts +77 -0
- package/dist/core.js +64 -0
- package/dist/evaluation/code_executor.d.ts +2 -0
- package/dist/evaluation/code_executor.js +104 -0
- package/dist/evaluation/eval_worker.d.ts +1 -0
- package/dist/evaluation/eval_worker.js +53 -0
- package/dist/http/handlers/mcp.d.ts +2 -0
- package/dist/http/handlers/shell.d.ts +6 -0
- package/dist/http/index.d.ts +15 -0
- package/dist/http/index.js +33963 -0
- package/dist/http/security.d.ts +12 -0
- package/dist/http/security.js +132 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.js +117 -231
- package/dist/mcp.d.ts +2 -0
- package/dist/mcp.js +13968 -945
- package/dist/next-js.d.ts +15 -0
- package/dist/next-js.js +40304 -0
- package/dist/resolution/formatters.d.ts +5 -0
- package/dist/resolution/formatters.js +2 -0
- package/dist/resolution/index.d.ts +6 -0
- package/dist/resolution/index.js +18 -219
- package/dist/resolution/module-resolver.d.ts +8 -0
- package/dist/resolution/module-resolver.js +10 -213
- package/dist/resolution/symbol-finder.d.ts +4 -0
- package/dist/resolution/symbol-finder.js +32 -237
- package/dist/resolution/utils.d.ts +5 -0
- package/dist/resolution/utils.js +5 -211
- package/dist/tools.d.ts +58 -0
- package/dist/tools.js +4099 -0
- package/dist/vite-plugin.d.ts +3 -0
- package/dist/vite-plugin.js +33986 -0
- package/package.json +28 -2
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { NextApiRequest, NextApiResponse } from 'next';
|
|
2
|
+
import { NextResponse, type NextRequest } from 'next/server';
|
|
3
|
+
import { type Request, type Response } from './http';
|
|
4
|
+
import type { TidewaveConfig } from './core';
|
|
5
|
+
type NextJsHandler = (_req: NextApiRequest, _res: NextApiResponse) => Promise<void>;
|
|
6
|
+
type NextJsMiddleware = (_req: NextRequest) => Promise<NextResponse>;
|
|
7
|
+
type NextHandler = () => ValueOrPromise<unknown>;
|
|
8
|
+
export type FunctionLike = (...args: any[]) => unknown;
|
|
9
|
+
export type Nextable<H extends FunctionLike> = (...args: [...Parameters<H>, NextHandler]) => ValueOrPromise<any>;
|
|
10
|
+
export type ValueOrPromise<T> = T | Promise<T>;
|
|
11
|
+
export type RequestHandler<Req extends Request, Res extends Response> = (req: Req, res: Res) => ValueOrPromise<void>;
|
|
12
|
+
export declare function tidewaveHandler(config?: TidewaveConfig): Promise<NextJsHandler>;
|
|
13
|
+
export declare function tidewaveMiddleware(): NextJsMiddleware;
|
|
14
|
+
export declare function isTidewaveRoute(pathname: string): boolean;
|
|
15
|
+
export {};
|