import { App } from "https://deno.land/x/alosaur@v0.38.0/src/mod.ts";
Constructors
new
App(settings: AppSettings)Properties
private
optional
_globalErrorHandler: (ctx: HttpContext<TState>, error: Error) => voidprivate
_routes: RouteMetadata[]private
optional
_staticConfig: StaticFilesConfigprivate
classes: ObjectKeyAny[]private
listener: Deno.Listener | undefinedprivate
readonly
metadata: MetadataArgsStorage<TState>private
viewRenderConfig: ViewRenderConfig | undefinedoptional
_transformConfigMap: TransformConfigMapreadonly
globalErrorHandler: ((ctx: HttpContext<TState>, error: Error) => void) | undefinedreadonly
routes: RouteMetadata[]readonly
staticConfig: StaticFilesConfig | undefinedreadonly
transformConfigMap: TransformConfigMap | undefinedMethods
private
isRunFullServer(): booleanprivate
sortMiddlewares(settings: AppSettings)close(): void
error(globalErrorHandler: (ctx: HttpContext<TState>, error: Error) => void): void
Create one global error handler
listen(address?: string | Deno.ListenOptions, customListener?: Deno.Listener): Promise<any>
Listen requests on server with support custom listener
use(route: RegExp, middleware: IMiddleware<TState>): void
useCors(builder: CorsBuilder<TState>): void
Deprecate
useStatic(config?: StaticFilesConfig): void
useTransform(transform: TransformConfig): void
useViewRender(config?: ViewRenderConfig): void