You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
using the structuredClone() function, as it creates a deep copy of the object, which means it will lose any functions, getters, or setters that were defined on the original object. Instead, you will end up with a plain object that only contains the data properties.
Description:
When using thegetPropsCopy()method to create a copy of an entity object, the StructuredClone() function is converting the entity object into a plain object. This is causing issues when calling the getters for properties of the entity object.
For example, when trying to access the address.country, address.postalCode, and address.street getters of a UserEntity object, the properties are returning undefined due to the conversion of the object by StructuredClone().
This issue seems to be related to the StructuredClone() function, and may be causing similar issues in other parts of the application.
I'm impressed with the speed of your response! Thank you so much @Sairyss .
I will make sure to pull the latest changes and keep you informed of any updates.
Summary
using the
structuredClone()
function, as it creates a deep copy of the object, which means it will lose any functions, getters, or setters that were defined on the original object. Instead, you will end up with a plain object that only contains the data properties.Description:
When using the
getPropsCopy()
method to create a copy of an entity object, theStructuredClone()
function is converting the entity object into a plain object. This is causing issues when calling the getters for properties of the entity object.For example, when trying to access the
address.country
,address.postalCode
, andaddress.street
getters of a UserEntity object, the properties are returningundefined
due to the conversion of the object byStructuredClone().
This issue seems to be related to the
StructuredClone()
function, and may be causing similar issues in other parts of the application.Steps to Reproduce:
ref to. >
getPropsCopy()
method to create a copy of the object.address.country
,address.postalCode,
andaddress.street
getters of the copied object.Expected Result:
The
address.country
,address.postalCode
, andaddress.street
getters should return the expected values.Actual Result:
The
address.country
,address.postalCode
, andaddress.street
getters are returningundefined
.The text was updated successfully, but these errors were encountered: