Skip to main content
Module

x/alosaur/mod.ts>CorsBuilder

Alosaur - Deno web framework with many decorators
Very Popular
Go to Latest
class CorsBuilder
implements MiddlewareTarget<T>
Re-export
import { CorsBuilder } from "https://deno.land/x/alosaur@v0.35.2/mod.ts";

Constructors

new
CorsBuilder()

Properties

private
allowAnyHeader: boolean
private
allowAnyMethod: boolean
private
allowAnyOrigin: boolean
private
headers: Map<string, string>

Methods

onPostRequest(context: HttpContext<T>): Promise<void>
onPreRequest(context: HttpContext<T>): Promise<void>
WithHeaders(headers: string)
WithMethods(methods: string)
WithOrigins(origins: string)