Skip to content

feat(useSocketEvent): provide option for schema validation #4

@kamiloox

Description

@kamiloox

Currently fields that are returned by useSocketEvent are not validated. It would be great to have an opportunity to pass a schema as an optional argument.
It needs to be done as much schema validation library agnostic as possible. Do not implement it to support only specific validation libraries like e.g. zod, yod or joi. Check if it's possible to validate it asynchronously to either resolve it successfully or throw an error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions