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

Make clear that Typia does not perform class conversion #869

Closed
a-kla opened this issue Nov 13, 2023 · 3 comments
Closed

Make clear that Typia does not perform class conversion #869

a-kla opened this issue Nov 13, 2023 · 3 comments
Assignees
Labels
documentation Improvements or additions to documentation

Comments

@a-kla
Copy link

a-kla commented Nov 13, 2023

Example

⏯ Playground Link <= first take a look at this

Feature Request

Please update the Documentation and point out that Typia only works well with primitive types.

It's frustrating if you use a Validator to prevent runtime errors but just get them on another unexpected Place.

It's known that Typia don't work with classes (creates a Object without the methods).
@ samchon/nestia#431

Current nestia does not performan class conversion, and recommends to use pure interface type instead.

But no Words about it in the Typia Documentation.

And I don't understand why typia.createRandom<Date>() returns to a valid Date class but
typia.json.assertParse<Date>(new Date().toISOString()); asserts a string as Date.

@samchon
Copy link
Owner

samchon commented Nov 14, 2023

Got it, will write the word that typia is not write the intanceof statement.

@samchon samchon changed the title Make clear that Typia does not perform class conversion => Typia is not 100% Type-safe Make clear that Typia does not perform class conversion Nov 17, 2023
samchon added a commit that referenced this issue Nov 17, 2023
@samchon samchon self-assigned this Nov 17, 2023
@samchon samchon added the documentation Improvements or additions to documentation label Nov 17, 2023
@samchon
Copy link
Owner

samchon commented Nov 18, 2023

image

New section "Restriction" would be newly added at v5.3 update

@AlexRMU
Copy link
Contributor

AlexRMU commented Aug 14, 2024

Close as completed?

@samchon samchon closed this as completed Aug 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

3 participants