Closed Slarper closed 4 months ago
Hello @Slarper,
I am unable to reproduce your error with the example you've provided. It works for me as expected.
What environment you run this in? ts version and ts target?
Does it work for you if you add the @Type(() => BigInt)
type decorator on top of your bigint field?
Also why do you have [0];
at the end of your plainToInstance
? It will not return an array.
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Description
When
plainToInstance
converted a plain object contains bigint fields, it crashed and output:Minimal code-snippet showcasing the problem
Expected behavior
It should convert the object successfully.
Actual behavior
It crashed.