CorsOptions class

CORS options.

Constructors

CorsOptions({List<String> allowedOrigins = const ['*'], List<String> allowedMethods = const ['GET', 'POST', 'PUT', 'DELETE', 'OPTIONS'], List<String> allowedHeaders = const ['*'], bool allowCredentials = false, int? maxAge})
Default constructor.
const

Properties

allowCredentials bool
Allow credentials flag.
final
allowedHeaders List<String>
Allowed headers.
final
allowedMethods List<String>
Allowed methods.
final
allowedOrigins List<String>
Allowed origins.
final
hashCode int
The hash code for this object.
no setterinherited
maxAge int?
Max age cache in seconds.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited