0
0
mirror of https://github.com/PostHog/posthog.git synced 2024-11-22 08:40:03 +01:00
posthog/hogvm/__tests__/properties.hog
2024-07-18 14:20:38 +02:00

81 lines
1.4 KiB
Plaintext

{
let r := [1, 2, {'d': (1, 3, 42, 6)}]
print(r.3.d.2)
}
{
let r := [1, 2, {'d': (1, 3, 42, 6)}]
print(r[3].d[3])
}
{
let r := [1, 2, {'d': (1, 3, 42, 6)}]
print(r.3['d'][4])
}
{
let r := {'d': (1, 3, 42, 6)}
print(r.d.2)
}
{
let r := [1, 2, {'d': [1, 3, 42, 3]}]
r.3.d.3 := 3
print(r.3.d.3)
}
{
let r := [1, 2, {'d': [1, 3, 42, 3]}]
r[3].d[3] := 3
print(r[3].d[3])
}
{
let r := [1, 2, {'d': [1, 3, 42, 3]}]
r[3].c := [666]
print(r[3])
}
{
let r := [1, 2, {'d': [1, 3, 42, 3]}]
r[3].d[3] := 3
print(r[3].d)
}
{
let r := [1, 2, {'d': [1, 3, 42, 3]}]
r.3['d'] := ['a', 'b', 'c', 'd']
print(r[3].d[3])
}
{
let r := [1, 2, {'d': [1, 3, 42, 3]}]
let g := 'd'
r.3[g] := ['a', 'b', 'c', 'd']
print(r[3].d[3])
}
{
let event := {
'event': '$pageview',
'properties': {
'$browser': 'Chrome',
'$os': 'Windows'
}
}
event['properties']['$browser'] := 'Firefox'
print(event)
}
{
let event := {
'event': '$pageview',
'properties': {
'$browser': 'Chrome',
'$os': 'Windows'
}
}
event.properties.$browser := 'Firefox'
print(event)
}
{
let event := {
'event': '$pageview',
'properties': {
'$browser': 'Chrome',
'$os': 'Windows'
}
}
let config := {}
print(event)
}