Conchoid on Nostr: Oh no in JS function created by Function() constructor, `this` is the window object. ...
Oh no in JS function created by Function() constructor, `this` is the window object. I just thought I can have static variables, but this way they are too permanent :)
Published at
2026-08-08 19:21:24 UTCEvent JSON
{
"id": "c12d1172cfa2a1dfeeff72c4decfd11c5bbc451d5f8644d6c9b6c630e0af3c9e",
"pubkey": "87e1e4a9cf8344e3b1f496e44d4ab27b325b8993400cd519e2ae4d3404b182d0",
"created_at": 1786216884,
"kind": 1,
"tags": [
[
"proxy",
"https://mastodon.gamedev.place/@conchoid/117061509727611322",
"web"
],
[
"proxy",
"https://mastodon.gamedev.place/users/conchoid/statuses/117061509727611322",
"activitypub"
],
[
"L",
"pink.momostr"
],
[
"l",
"pink.momostr.activitypub:https://mastodon.gamedev.place/users/conchoid/statuses/117061509727611322",
"pink.momostr"
],
[
"-"
]
],
"content": "Oh no in JS function created by Function() constructor, `this` is the window object. I just thought I can have static variables, but this way they are too permanent :)",
"sig": "67029433a819d0cdd8ebc069a012cf4ea8e5f6bbc862a45b1bac7d51f42de92a4c8f568cddae4696290333afe2d2b8a619d119100718393d68df145a3f7615b8"
}