Skip to content
New issue

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

Create parameter decorator shortcuts for the object type #1607

Closed
2 tasks
jannyHou opened this issue Aug 14, 2018 · 4 comments
Closed
2 tasks

Create parameter decorator shortcuts for the object type #1607

jannyHou opened this issue Aug 14, 2018 · 4 comments
Labels
developer-experience Issues affecting ease of use and overall experience of LB users

Comments

@jannyHou
Copy link
Contributor

jannyHou commented Aug 14, 2018

Description / Steps to reproduce / Feature proposal

Inspired by issue #100.

We should create decorator shortcuts for object parameters from:

  • query
  • header
  • path

The shortcut should be able to infer the schema from the type metadata.

For example:

import {Note} from '../models'
class MyController {
  @get('/test')
  async test(@param.query.object('note') note: Note) {
    // your code
  }: void
}

Acceptance Criteria

  • create shortcuts
    • @param.query.object

NOTE: Objects are rarely if ever passed in via a path parameter or header as such those decorators are not to be added as part of this task. If someone decides to pass them via those areas, they can do so using the full @param decorator.

@dhmlau
Copy link
Member

dhmlau commented Aug 14, 2018

@jannyHou , I'm thinking this is post GA since it's enhancement on the developer experience or convenience. what do you think?

@virkt25
Copy link
Contributor

virkt25 commented Aug 15, 2018

This was discussed during estimation and agreed to be a post-GA task.

@virkt25 virkt25 added post-GA developer-experience Issues affecting ease of use and overall experience of LB users labels Aug 15, 2018
@jannyHou
Copy link
Contributor Author

jannyHou commented Aug 15, 2018

@dhmlau 👍 post-GA sounds good

@bajtos
Copy link
Member

bajtos commented Oct 30, 2018

Closing as implemented via #1667

@bajtos bajtos closed this as completed Oct 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
developer-experience Issues affecting ease of use and overall experience of LB users
Projects
None yet
Development

No branches or pull requests

4 participants