Upgraded lints to 3.0.0
This commit is contained in:
parent
cfe1ef8189
commit
d4794dbbd1
48 changed files with 149 additions and 113 deletions
|
@ -1,5 +1,9 @@
|
|||
# Change Log
|
||||
|
||||
## 8.1.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
|
||||
## 8.0.0
|
||||
|
||||
* Require Dart >= 3.0
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
name: angel3_auth
|
||||
description: A complete authentication plugin for Angel3. Includes support for stateless JWT tokens, Basic Auth, and more.
|
||||
version: 8.0.0
|
||||
version: 8.1.0
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/auth
|
||||
environment:
|
||||
|
@ -19,7 +19,7 @@ dev_dependencies:
|
|||
http: ^1.0.0
|
||||
io: ^1.0.0
|
||||
test: ^1.24.0
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
||||
# dependency_overrides:
|
||||
# angel3_container:
|
||||
# path: ../container/angel_container
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
# Change Log
|
||||
|
||||
## 8.1.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
* Fixed linter warnings
|
||||
|
||||
## 8.0.0
|
||||
|
||||
* Require Dart >= 3.0
|
||||
|
|
|
@ -48,8 +48,7 @@ class RestService<Id, Data> extends BaseAngelService<Id, Data> {
|
|||
|
||||
final Type? type;
|
||||
|
||||
RestService(http.BaseClient client, BaseAngelClient app, url, this.type)
|
||||
: super(client, app, url);
|
||||
RestService(super.client, super.app, super.url, this.type);
|
||||
|
||||
@override
|
||||
Data? deserialize(x) {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
name: angel3_client
|
||||
version: 8.0.0
|
||||
version: 8.1.0
|
||||
description: A browser, mobile and command line based client that supports querying Angel3 servers
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/client
|
||||
|
@ -24,7 +24,7 @@ dev_dependencies:
|
|||
build_runner: ^2.4.0
|
||||
build_web_compilers: ^4.0.0
|
||||
test: ^1.24.0
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
||||
# dependency_overrides:
|
||||
# angel3_container:
|
||||
# path: ../container/angel_container
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
# Change Log
|
||||
|
||||
## 8.1.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
|
||||
## 8.0.0
|
||||
|
||||
* Require Dart >= 3.0
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
name: angel3_configuration
|
||||
version: 8.0.0
|
||||
version: 8.1.0
|
||||
description: Automatic YAML application configuration loader for Angel 3, with .env support.
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/configuration
|
||||
|
@ -14,7 +14,7 @@ dependencies:
|
|||
dev_dependencies:
|
||||
io: ^1.0.0
|
||||
logging: ^1.2.0
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
||||
belatuk_pretty_logging: ^6.0.0
|
||||
test: ^1.24.0
|
||||
# dependency_overrides:
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
# Change Log
|
||||
|
||||
## 8.1.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
* Fixed analyser warnings
|
||||
|
||||
## 8.0.0
|
||||
|
||||
* Require Dart >= 3.0
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
name: angel3_container
|
||||
version: 8.0.0
|
||||
version: 8.1.0
|
||||
description: Angel3 hierarchical DI container, and pluggable backends for reflection.
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/container/angel_container
|
||||
|
@ -10,4 +10,4 @@ dependencies:
|
|||
quiver: ^3.2.0
|
||||
dev_dependencies:
|
||||
test: ^1.24.0
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
|
@ -116,7 +116,7 @@ class Pokemon {
|
|||
}
|
||||
|
||||
class KantoPokemon extends Pokemon {
|
||||
KantoPokemon(String name, PokemonType type) : super(name, type);
|
||||
KantoPokemon(super.name, super.type);
|
||||
}
|
||||
|
||||
enum PokemonType { water, fire, grass, ice, poison, flying }
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
# Change Log
|
||||
|
||||
## 8.1.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
* Fixed analyser warnings
|
||||
|
||||
## 8.0.0
|
||||
|
||||
* Require Dart >= 3.0
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
[![Gitter](https://img.shields.io/gitter/room/angel_dart/discussion)](https://gitter.im/angel_dart/discussion)
|
||||
[![License](https://img.shields.io/github/license/dukefirehawk/angel)](https://github.com/dukefirehawk/angel/tree/master/packages/container/angel3_container_generator/LICENSE)
|
||||
|
||||
An alternative container for Angel3 that uses `reflectable` package instead of `dart:mirrors` for reflection. However, `reflectable` has much limited relfection capabilities when compared to `dart:mirrors`.
|
||||
An alternative container for Angel3 that uses `reflectable` package instead of `dart:mirrors` for reflection. However, `reflectable` has more limited relfection capabilities when compared to `dart:mirrors`.
|
||||
|
||||
## Usage
|
||||
|
||||
|
@ -26,6 +26,7 @@ An alternative container for Angel3 that uses `reflectable` package instead of `
|
|||
|
||||
## Known limitation
|
||||
|
||||
* `analyser` 6.x is not supported due to `reflectable`
|
||||
* Reflection on functions/closures is not supported
|
||||
* Reflection on private declarations is not supported
|
||||
* Reflection on generic type is not supported
|
||||
|
|
|
@ -426,7 +426,7 @@ final _data = <r.Reflectable, r.ReflectorData>{
|
|||
},
|
||||
4,
|
||||
10,
|
||||
const <int>[],
|
||||
const <int>[15],
|
||||
const [],
|
||||
null,
|
||||
(o) => false,
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
name: angel3_container_generator
|
||||
version: 8.0.0
|
||||
version: 8.1.0
|
||||
description: Codegen support for using pkg:reflectable with pkg:angel3_container.
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/container/angel_container_generator
|
||||
|
@ -12,7 +12,7 @@ dev_dependencies:
|
|||
build_runner: ^2.4.0
|
||||
build_test: ^2.1.0
|
||||
test: ^1.24.0
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
||||
# dependency_overrides:
|
||||
# angel3_container:
|
||||
# path: ../angel_container
|
||||
|
|
|
@ -142,7 +142,7 @@ class Pokemon {
|
|||
|
||||
@contained
|
||||
class KantoPokemon extends Pokemon {
|
||||
KantoPokemon(String name, PokemonType type) : super(name, type);
|
||||
KantoPokemon(super.name, super.type);
|
||||
}
|
||||
|
||||
@contained
|
||||
|
|
|
@ -641,7 +641,7 @@ final _data = <r.Reflectable, r.ReflectorData>{
|
|||
},
|
||||
2,
|
||||
18,
|
||||
const <int>[],
|
||||
const <int>[23],
|
||||
const [],
|
||||
null,
|
||||
(o) => false,
|
||||
|
@ -3598,7 +3598,7 @@ final _data = <r.Reflectable, r.ReflectorData>{
|
|||
null),
|
||||
r.ParameterMirrorImpl(
|
||||
r'name',
|
||||
134348806,
|
||||
134349830,
|
||||
70,
|
||||
const prefix0.ContainedReflectable(),
|
||||
15,
|
||||
|
@ -3610,7 +3610,7 @@ final _data = <r.Reflectable, r.ReflectorData>{
|
|||
null),
|
||||
r.ParameterMirrorImpl(
|
||||
r'type',
|
||||
134348806,
|
||||
134349830,
|
||||
70,
|
||||
const prefix0.ContainedReflectable(),
|
||||
6,
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
# Change Log
|
||||
|
||||
## 8.3.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
* Fixed linter warnings
|
||||
|
||||
## 8.2.0
|
||||
|
||||
* Add `addResponseHeader` to `AngelHttp` to add headers to HTTP default response
|
||||
|
|
|
@ -1,6 +1,4 @@
|
|||
import 'dart:async';
|
||||
import 'request_context.dart';
|
||||
import 'response_context.dart';
|
||||
import 'service.dart';
|
||||
|
||||
/// An easy helper class to create one-off services without having to create an entire class.
|
||||
|
@ -22,8 +20,7 @@ class AnonymousService<Id, Data> extends Service<Id, Data> {
|
|||
FutureOr<Data> Function(Id id, Data data, [Map<String, dynamic>? params])?
|
||||
update,
|
||||
FutureOr<Data> Function(Id id, [Map<String, dynamic>? params])? remove,
|
||||
FutureOr<Data> Function(RequestContext, ResponseContext)? readData})
|
||||
: super(readData: readData) {
|
||||
super.readData}) {
|
||||
_index = index;
|
||||
_read = read;
|
||||
_create = create;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
part of angel_framework.http.request_context;
|
||||
part of 'request_context.dart';
|
||||
|
||||
const List<Type> _primitiveTypes = [String, int, num, double, Null];
|
||||
|
||||
|
|
|
@ -141,40 +141,26 @@ class Parameter {
|
|||
|
||||
/// Shortcut for declaring a request header [Parameter].
|
||||
class Header extends Parameter {
|
||||
const Header(String header, {match, defaultValue, bool required = true})
|
||||
: super(
|
||||
header: header,
|
||||
match: match,
|
||||
defaultValue: defaultValue,
|
||||
required: required);
|
||||
const Header(String header, {super.match, super.defaultValue, super.required})
|
||||
: super(header: header);
|
||||
}
|
||||
|
||||
/// Shortcut for declaring a request session [Parameter].
|
||||
class Session extends Parameter {
|
||||
const Session(String session, {match, defaultValue, bool required = true})
|
||||
: super(
|
||||
session: session,
|
||||
match: match,
|
||||
defaultValue: defaultValue,
|
||||
required: required);
|
||||
const Session(String session,
|
||||
{super.match, super.defaultValue, super.required})
|
||||
: super(session: session);
|
||||
}
|
||||
|
||||
/// Shortcut for declaring a request query [Parameter].
|
||||
class Query extends Parameter {
|
||||
const Query(String query, {match, defaultValue, bool required = true})
|
||||
: super(
|
||||
query: query,
|
||||
match: match,
|
||||
defaultValue: defaultValue,
|
||||
required: required);
|
||||
const Query(String query, {super.match, super.defaultValue, super.required})
|
||||
: super(query: query);
|
||||
}
|
||||
|
||||
/// Shortcut for declaring a request cookie [Parameter].
|
||||
class CookieValue extends Parameter {
|
||||
const CookieValue(String cookie, {match, defaultValue, bool required = true})
|
||||
: super(
|
||||
cookie: cookie,
|
||||
match: match,
|
||||
defaultValue: defaultValue,
|
||||
required: required);
|
||||
const CookieValue(String cookie,
|
||||
{super.match, super.defaultValue, super.required})
|
||||
: super(cookie: cookie);
|
||||
}
|
||||
|
|
|
@ -26,8 +26,8 @@ class AngelHttp extends Driver<HttpRequest, HttpResponse, HttpServer,
|
|||
scheme: 'http', host: server?.address.address, port: server?.port);
|
||||
}
|
||||
|
||||
AngelHttp._(Angel app, ServerGeneratorType serverGenerator, bool useZone)
|
||||
: super(app, serverGenerator, useZone: useZone);
|
||||
AngelHttp._(super.app, super.serverGenerator, bool useZone)
|
||||
: super(useZone: useZone);
|
||||
|
||||
factory AngelHttp(Angel app, {bool useZone = true}) {
|
||||
return AngelHttp._(app, HttpServer.bind, useZone);
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
name: angel3_framework
|
||||
version: 8.2.0
|
||||
version: 8.3.0
|
||||
description: A high-powered HTTP server extensible framework with dependency injection, routing and much more.
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/framework
|
||||
|
@ -11,9 +11,9 @@ dependencies:
|
|||
angel3_model: ^8.0.0
|
||||
angel3_route: ^8.0.0
|
||||
angel3_mock_request: ^8.0.0
|
||||
belatuk_merge_map: ^5.0.0
|
||||
belatuk_combinator: ^5.0.0
|
||||
belatuk_http_server: ^4.0.0
|
||||
belatuk_merge_map: ^5.1.0
|
||||
belatuk_combinator: ^5.1.0
|
||||
belatuk_http_server: ^4.1.0
|
||||
charcode: ^1.3.0
|
||||
file: ^7.0.0
|
||||
http_parser: ^4.0.0
|
||||
|
@ -34,7 +34,7 @@ dev_dependencies:
|
|||
http: ^1.0.0
|
||||
io: ^1.0.0
|
||||
test: ^1.24.0
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
||||
# dependency_overrides:
|
||||
# angel3_container:
|
||||
# path: ../container/angel_container
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
|
||||
# Change Log
|
||||
|
||||
## 8.1.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
|
||||
## 8.0.0
|
||||
|
||||
* Require Dart >= 3.0
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
name: angel3_http_exception
|
||||
version: 8.0.0
|
||||
version: 8.1.0
|
||||
description: Exception class that can be serialized to JSON and serialized to clients.
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/http_exception
|
||||
environment:
|
||||
sdk: '>=3.0.0 <4.0.0'
|
||||
dev_dependencies:
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
|
@ -1,5 +1,9 @@
|
|||
# Change Log
|
||||
|
||||
## 8.1.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
|
||||
## 8.0.0
|
||||
|
||||
* Require Dart >= 3.0
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
name: angel3_mock_request
|
||||
version: 8.0.0
|
||||
version: 8.1.0
|
||||
description: Manufacture dart:io HttpRequests, HttpResponses, HttpHeaders, etc.
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/mock_request
|
||||
|
@ -11,7 +11,7 @@ dev_dependencies:
|
|||
#angel3_framework: ^7.0.0
|
||||
http: ^1.0.0
|
||||
test: ^1.24.0
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
||||
# dependency_overrides:
|
||||
# angel3_framework:
|
||||
# path: ../framework
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
# Change Log
|
||||
|
||||
## 8.1.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
* Fixed analyser warnings
|
||||
|
||||
## 8.0.0
|
||||
|
||||
* Require Dart >= 3.0
|
||||
|
|
|
@ -11,10 +11,9 @@ class Todo extends Model {
|
|||
bool isComplete;
|
||||
|
||||
Todo(
|
||||
{required String id,
|
||||
{required String super.id,
|
||||
this.text,
|
||||
this.isComplete = false,
|
||||
DateTime? createdAt,
|
||||
DateTime? updatedAt})
|
||||
: super(id: id, createdAt: createdAt, updatedAt: updatedAt);
|
||||
super.createdAt,
|
||||
super.updatedAt});
|
||||
}
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
name: angel3_model
|
||||
version: 8.0.0
|
||||
version: 8.1.0
|
||||
description: Angel3 basic data model class, no longer with the added weight of the whole framework.
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/model
|
||||
environment:
|
||||
sdk: '>=3.0.0 <4.0.0'
|
||||
dev_dependencies:
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
[![Gitter](https://img.shields.io/gitter/room/angel_dart/discussion)](https://gitter.im/angel_dart/discussion)
|
||||
[![License](https://img.shields.io/github/license/dukefirehawk/angel)](https://github.com/dukefirehawk/angel/tree/master/packages/orm/angel_orm_mysql/LICENSE)
|
||||
|
||||
This package contains the SQL executor required by Angel3 ORM to work with MySQL and MariaDB respectively. In order to better support both MySQL and MariaDB, two different flavors of drives have been included; `mysql_client` and `mysql1`. They are implmented as `MySqlExecutor` and `MariaDbExecutor` respectively.
|
||||
This package contains the SQL executor required by Angel3 ORM to work with MySQL or MariaDB. In order to better support both MySQL and MariaDB, two different flavors of drives have been included; `mysql_client` and `mysql1`. They are implmented as `MySqlExecutor` and `MariaDbExecutor` respectively.
|
||||
|
||||
## Supported databases
|
||||
|
||||
|
@ -73,23 +73,23 @@ This SQL executor is implemented using [`mysql1`](https://pub.dev/packages?q=mys
|
|||
|
||||
1. Login to MariaDB/MySQL database console with the following command.
|
||||
|
||||
```bash
|
||||
mysql -u root -p
|
||||
```
|
||||
```bash
|
||||
mysql -u root -p
|
||||
```
|
||||
|
||||
1. Run the following commands to create a new database, `orm_test` and grant both local and remote access to user, `test`. Replace `orm_test`, `test` and `test123` with your own database name, username and password respectively.
|
||||
2. Run the following commands to create a new database, `orm_test`, and grant both local and remote access to user, `test`. Replace `orm_test`, `test` and `test123` with your own database name, username and password.
|
||||
|
||||
```mysql
|
||||
create database orm_test;
|
||||
|
||||
-- Granting localhost access only
|
||||
create user 'test'@'localhost' identified by 'test123';
|
||||
grant all privileges on orm_test.* to 'test'@'localhost';
|
||||
```mysql
|
||||
create database orm_test;
|
||||
|
||||
-- Granting localhost access only
|
||||
create user 'test'@'localhost' identified by 'test123';
|
||||
grant all privileges on orm_test.* to 'test'@'localhost';
|
||||
|
||||
-- Granting localhost and remote access
|
||||
create user 'test'@'%' identified by 'test123';
|
||||
grant all privileges on orm_test.* to 'test'@'%';
|
||||
```
|
||||
-- Granting localhost and remote access
|
||||
create user 'test'@'%' identified by 'test123';
|
||||
grant all privileges on orm_test.* to 'test'@'%';
|
||||
```
|
||||
|
||||
## Compatibility Matrix
|
||||
|
||||
|
|
|
@ -114,7 +114,6 @@ class Runner {
|
|||
onError: onError.sendPort,
|
||||
errorsAreFatal: true && false)
|
||||
.then((isolate) {})
|
||||
//.catchError(c.completeError);
|
||||
.catchError((e) {
|
||||
c.completeError(e as Object);
|
||||
return null;
|
||||
|
@ -192,7 +191,8 @@ class Runner {
|
|||
server = Server([adapter]);
|
||||
|
||||
// Register clients
|
||||
for (var i = 0; i < Platform.numberOfProcessors; i++) {
|
||||
// for (var i = 0; i < Platform.numberOfProcessors; i++) {
|
||||
for (var i = 0; i < options.concurrency; i++) {
|
||||
server.registerClient(ClientInfo('client$i'));
|
||||
}
|
||||
|
||||
|
@ -248,13 +248,15 @@ class Runner {
|
|||
|
||||
if (args.options.ssl || args.options.http2) {
|
||||
securityContext = SecurityContext();
|
||||
if (args.options.certificateFile != null) {
|
||||
securityContext.useCertificateChain(args.options.certificateFile!,
|
||||
var certificateFile = args.options.certificateFile;
|
||||
if (certificateFile != null) {
|
||||
securityContext.useCertificateChain(certificateFile,
|
||||
password: args.options.certificatePassword);
|
||||
}
|
||||
|
||||
if (args.options.keyFile != null) {
|
||||
securityContext.usePrivateKey(args.options.keyFile!,
|
||||
var keyFile = args.options.keyFile;
|
||||
if (keyFile != null) {
|
||||
securityContext.usePrivateKey(keyFile,
|
||||
password: args.options.keyPassword);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
# Change Log
|
||||
|
||||
## 8.1.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
* Fixed analyser warnings
|
||||
|
||||
## 8.0.0
|
||||
|
||||
* Require Dart >= 3.0
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
part of angel3_route.src.router;
|
||||
part of 'router.dart';
|
||||
|
||||
class RouteGrammar {
|
||||
static const String notSlashRgx = r'([^/]+)';
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
part of angel3_route.src.router;
|
||||
part of 'router.dart';
|
||||
|
||||
/// Represents a virtual location within an application.
|
||||
class Route<T> {
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
part of angel3_route.src.router;
|
||||
part of 'router.dart';
|
||||
|
||||
/// Represents a complex result of navigating to a path.
|
||||
class RoutingResult<T> {
|
||||
|
|
|
@ -1,9 +1,8 @@
|
|||
part of angel3_route.src.router;
|
||||
part of 'router.dart';
|
||||
|
||||
/// Placeholder [Route] to serve as a symbolic link
|
||||
/// to a mounted [Router].
|
||||
class SymlinkRoute<T> extends Route<T> {
|
||||
final Router<T> router;
|
||||
SymlinkRoute(String path, this.router)
|
||||
: super(path, method: 'GET', handlers: <T>[]);
|
||||
SymlinkRoute(super.path, this.router) : super(method: 'GET', handlers: <T>[]);
|
||||
}
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
name: angel3_route
|
||||
version: 8.0.0
|
||||
version: 8.1.0
|
||||
description: A powerful, isomorphic routing library for Dart. It is mainly used in the Angel3 framework, but can be used in Flutter and on the Web.
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/route
|
||||
environment:
|
||||
sdk: '>=3.0.0 <4.0.0'
|
||||
dependencies:
|
||||
belatuk_combinator: ^5.0.0
|
||||
belatuk_combinator: ^5.1.0
|
||||
string_scanner: ^1.2.0
|
||||
path: ^1.8.0
|
||||
dev_dependencies:
|
||||
|
@ -14,4 +14,4 @@ dev_dependencies:
|
|||
build_web_compilers: ^4.0.0
|
||||
http: ^1.0.0
|
||||
test: ^1.24.0
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
# Change Log
|
||||
|
||||
## 8.1.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
|
||||
## 8.0.2
|
||||
|
||||
* Fixed incorrect mismatch message handling
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
name: angel3_validate
|
||||
description: Cross-platform HTTP request body validator library based on `matcher`.
|
||||
version: 8.0.2
|
||||
version: 8.1.0
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/validate
|
||||
environment:
|
||||
|
@ -14,7 +14,7 @@ dev_dependencies:
|
|||
build_runner: ^2.4.0
|
||||
build_web_compilers: ^4.0.0
|
||||
logging: ^1.2.0
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
||||
test: ^1.24.0
|
||||
# dependency_overrides:
|
||||
# angel3_container:
|
||||
|
|
|
@ -1,5 +1,11 @@
|
|||
# Change Log
|
||||
|
||||
## 8.1.0
|
||||
|
||||
* Updated `lints` to 3.0.0
|
||||
* Fixed linter warnings
|
||||
* Locked `web_socket_channel` to 2.4.0 temporarily. Starting with 2.4.1, its dependency on `dart:html` has been changed to `package:web` which is still highly experimental.
|
||||
|
||||
## 8.0.0
|
||||
|
||||
* Require Dart >= 3.0
|
||||
|
|
|
@ -3,7 +3,6 @@ import 'dart:collection';
|
|||
import 'dart:convert';
|
||||
import 'package:angel3_client/angel3_client.dart';
|
||||
import 'package:angel3_client/base_angel_client.dart';
|
||||
import 'package:http/http.dart';
|
||||
import 'package:web_socket_channel/web_socket_channel.dart';
|
||||
import 'package:web_socket_channel/status.dart' as status;
|
||||
import 'angel3_websocket.dart';
|
||||
|
@ -85,9 +84,8 @@ abstract class BaseWebSocketClient extends BaseAngelClient {
|
|||
}
|
||||
}
|
||||
|
||||
BaseWebSocketClient(BaseClient client, baseUrl,
|
||||
{this.reconnectOnClose = true, Duration? reconnectInterval})
|
||||
: super(client, baseUrl) {
|
||||
BaseWebSocketClient(super.client, super.baseUrl,
|
||||
{this.reconnectOnClose = true, Duration? reconnectInterval}) {
|
||||
_reconnectInterval = reconnectInterval ?? Duration(seconds: 10);
|
||||
}
|
||||
|
||||
|
|
|
@ -106,7 +106,6 @@ class WebSockets extends BaseWebSocketClient {
|
|||
class BrowserWebSocketsService<Id, Data> extends WebSocketsService<Id, Data> {
|
||||
final Type? type;
|
||||
|
||||
BrowserWebSocketsService(WebSocketChannel? socket, WebSockets app, String uri,
|
||||
{this.type, AngelDeserializer<Data>? deserializer})
|
||||
: super(socket, app, uri, deserializer: deserializer);
|
||||
BrowserWebSocketsService(super.socket, WebSockets super.app, super.uri,
|
||||
{this.type, super.deserializer});
|
||||
}
|
||||
|
|
|
@ -60,7 +60,5 @@ class WebSockets extends BaseWebSocketClient {
|
|||
class IoWebSocketsService<Id, Data> extends WebSocketsService<Id, Data> {
|
||||
final Type? type;
|
||||
|
||||
IoWebSocketsService(
|
||||
WebSocketChannel? socket, WebSockets app, String uri, this.type)
|
||||
: super(socket, app, uri);
|
||||
IoWebSocketsService(super.socket, WebSockets super.app, super.uri, this.type);
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
part of angel3_websocket.server;
|
||||
part of 'server.dart';
|
||||
|
||||
/// Represents a WebSocket session, with the original
|
||||
/// [RequestContext] and [ResponseContext] attached.
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
part of angel3_websocket.server;
|
||||
part of 'server.dart';
|
||||
|
||||
/// Marks a method as available to WebSockets.
|
||||
class ExposeWs {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
name: angel3_websocket
|
||||
version: 8.0.0
|
||||
version: 8.1.0
|
||||
description: This library provides WebSockets support for Angel3 framework.
|
||||
homepage: https://angel3-framework.web.app/
|
||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/websocket
|
||||
|
@ -14,7 +14,7 @@ dependencies:
|
|||
http: ^1.0.0
|
||||
meta: ^1.8.0
|
||||
stream_channel: ^2.1.0
|
||||
web_socket_channel: ^2.1.0
|
||||
web_socket_channel: 2.4.0
|
||||
collection: ^1.17.0
|
||||
logging: ^1.1.0
|
||||
dev_dependencies:
|
||||
|
@ -22,7 +22,8 @@ dev_dependencies:
|
|||
angel3_model: ^8.0.0
|
||||
quiver: ^3.2.0
|
||||
test: ^1.24.0
|
||||
lints: ^2.1.0
|
||||
lints: ^3.0.0
|
||||
file: ^7.0.0
|
||||
# dependency_overrides:
|
||||
# angel3_container:
|
||||
# path: ../container/angel_container
|
||||
|
|
|
@ -29,7 +29,7 @@ const Game johnVsBob = Game(playerOne: 'John', playerTwo: 'Bob');
|
|||
|
||||
@Expose('/game')
|
||||
class GameController extends WebSocketController {
|
||||
GameController(AngelWebSocket ws) : super(ws);
|
||||
GameController(super.ws);
|
||||
|
||||
@ExposeWs('search')
|
||||
dynamic search(WebSocketContext socket) async {
|
||||
|
|
|
@ -6,6 +6,7 @@ void main() {
|
|||
var app = WebSockets(window.location.origin);
|
||||
window.alert(app.baseUrl.toString());
|
||||
|
||||
// ignore: body_might_complete_normally_catch_error
|
||||
app.connect().catchError((_) {
|
||||
window.alert('no websocket');
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue