UNPKG

747 BTypeScriptView Raw
1import type { Multipart } from './src/multipart/main.js';
2import { MultipartFile } from './src/multipart/file.js';
3import type { FileValidationOptions } from './src/types.js';
4export { defineConfig } from './src/define_config.js';
5export { MultipartFile, Multipart };
6/**
7 * Extending request class with custom properties.
8 */
9declare module '@adonisjs/http-server' {
10 interface Request {
11 multipart: Multipart;
12 __raw_files: Record<string, MultipartFile | MultipartFile[]>;
13 allFiles(): Record<string, MultipartFile | MultipartFile[]>;
14 file(key: string, options?: Partial<FileValidationOptions>): MultipartFile | null;
15 files(key: string, options?: Partial<FileValidationOptions>): MultipartFile[];
16 }
17}