node-web-mvc
Version:
node spring mvc
17 lines (16 loc) • 669 B
TypeScript
import CorsConfiguration from './CorsConfiguration';
export default class CorsRegistration {
private readonly pathPattern;
private readonly config;
constructor(pathPattern: string);
allowedOrigins(...origins: string[]): this;
allowedMethods(...methods: string[]): this;
allowedHeaders(...headers: string[]): this;
exposedHeaders(...headers: string[]): this;
allowCredentials(allowCredentials: boolean): this;
allowOriginPatterns(...patterns: RegExp[]): this;
allowPrivateNetwork(allowPrivateNetwork: boolean): this;
maxAge(maxAge: number): this;
getPathPattern(): string;
getCorsConfiguration(): CorsConfiguration;
}