This change fixes serialization of slices when passed as argument to Evaluate().
I found two issues with how slices are serialized:
The original argument was directly modified (passed as a reference) to become a map. We now create a separate map.
Once serialized, we returned a slice of map which I believe is not expected. We now returned {"a": [..]}, which is what the python library does here.
I also added a few tests.
I discovered that passing floats and time will not work.
We do not correctly serialize valid floats but when I tried fixing it I got the following error:
playwright: arg.value.v: expected one of (null|undefined|NaN|Infinity|-Infinity|-0)
This change fixes serialization of slices when passed as argument to Evaluate(). I found two issues with how slices are serialized:
I also added a few tests.
I discovered that passing floats and time will not work. We do not correctly serialize valid floats but when I tried fixing it I got the following error:
playwright: arg.value.v: expected one of (null|undefined|NaN|Infinity|-Infinity|-0)
Unfortunately, I wasn't able to fix this.