We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Package name network
network
Describe the solution you'd like The ability to use decorators for example: @get('http://todo.api/todo/1') / @post('http://todo.api/todo')
@get('http://todo.api/todo/1')
@post('http://todo.api/todo')
Additional context Proposal example:
class TodoApi { @get<JsonApiRequest, JsonApiResponse>('http://todo.api/todo') Future<Iterable<Todo>> getAll(JsonApiRequest request, JsonApiResponse response) async { return List.from(response.toMap).map((map) => Todo.fromMap(map)); } @get<JsonApiRequest, JsonApiResponse>('http://todo.api/todo/${id}') Future<Todo> get(JsonApiRequest request, JsonApiResponse response) async { return Todo.fromMap(response.toMap); } @delete<JsonApiRequest, JsonApiResponse>('http://todo.api/todo/${id}') Future<Todo> delete(JsonApiRequest request, JsonApiResponse response) async { return response.toMap['success'] != null; } }
TODO
The text was updated successfully, but these errors were encountered:
SergeShkurko
No branches or pull requests
Package name
network
Describe the solution you'd like
The ability to use decorators for example:
@get('http://todo.api/todo/1')
/@post('http://todo.api/todo')
Additional context
Proposal example:
TODO
The text was updated successfully, but these errors were encountered: