angel3_cors 10.0.0
angel3_cors: ^10.0.0 copied to clipboard
Angel3 CORS middleware. Ported from expressjs/cors to Angel3 framework.
Change Log #
10.0.0 #
Breaking changes in 10.0.0 #
- Breaking:
origin: falsedisables CORS, as documented, where it allowed every origin withAccess-Control-Allow-Origin: * - Breaking: A refused origin, or a request without one, gets no
Access-Control-Allow-Originheader, where it gotfalse; its preflight is still answered - Breaking: Only a preflight request (
OPTIONS, as sent, with anAccess-Control-Request-Methodheader) is answered bycors; anotherOPTIONSrequest, or one madeOPTIONSby a method override, continues to the app's handlers, where it was answered withsuccessStatus - Breaking:
Access-Control-Allow-Headersis sent on preflights only, where the request'sAccess-Control-Request-Headerswere also echoed on other responses - Breaking: An
originof a typeCorsOptionsdoes not describe is anArgumentErrorof the constructor, where it allowed every origin
New in 10.0.0 #
originmay be an async predicate,Future<bool> Function(String)
Fixes in 10.0.0 #
- No origin: A request without an
Originheader, with a predicate ororigin: true, is answered, where it failed with a 500 preflightContinue: Leaves the preflight response open for the handlers aftercors, where it was closedVary:originis added to theVaryheader, where it replaced it, when the origin is reflected (a refused one's response too), so caches keep the responses of each origin apart; a fixedorigindoes not vary- Example: Allows headers, not a method, in
allowedHeaders, and itsdynamicCorsno longer allows every origin - Docs: The README tells how to install and use the package, and how to migrate from 9.x, and
CorsOptions.credentialstells that browsers refuse credentials with the defaultoriginof'*'
9.1.0 #
- Require Dart >= 3.13
9.0.0 #
- Require Dart >= 3.12
8.4.0 #
- Require Dart >= 3.8
- Updated
lintsto 6.0.0 - Updated dependencies to the latest release
8.3.0 #
- Require Dart >= 3.6
- Updated
lintsto 5.0.0 - Updated dependencies to the latest release
8.2.0 #
- Require Dart >= 3.3
- Updated
lintsto 4.0.0
8.1.1 #
- Updated repository link
8.1.0 #
- Updated
lintsto 3.0.0 - Fixed linter warnings
8.0.0 #
- Require Dart >= 3.0
7.0.0 #
- Require Dart >= 2.17
6.0.1 #
- Fixed analyze error
6.0.0 #
- Require Dart >= 2.16
5.0.0 #
- Skipped release
4.1.0 #
- Upgraded to
lintslinter
4.0.1 #
- Updated README
- All 15 unit tests passed
4.0.0 #
- Migrated to support Dart >= 2.12 NNBD
3.0.0 #
- Migrated to work with Dart >= 2.12 Non NNBD
2.0.0 #
- Updates for Dart 2 and Angel 2.