Skip to content

Expose whole Class #1213

Open
Open
@jianzhou520

Description

@jianzhou520

Description

The default behaviour of the plainToClass method is to set all properties from the plain object, even those which are not specified in the class.In our case, we make some Class as a validator, so other unknown properties are dangerous

Proposed solution

like @exclude() working whole Class, maby @expose() can do the same thing, otherwise we need add @expose() before every properties in validator Class

Metadata

Metadata

Assignees

No one assigned

    Labels

    flag: needs discussionIssues which needs discussion before implementation.type: featureIssues related to new features.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions