Helge Heß on Nostr: I'm thinking about how to do SwiftWebUI in a useful way. A big thing in web is state ...
I'm thinking about how to do SwiftWebUI in a useful way. A big thing in web is state handling, i.e. what would `@State` mean? In SwiftWebUI/WO this is just part of an in-server, sticky, session. Which is almost never what you want (and probably shouldn't be a convenience default).
Some state could be in a parameter, or a cookie, or an actual session, or in Redis.
But having the way of state handling part of the View feels a little icky, too tightly scoped.
Published at
2024-09-30 20:14:26Event JSON
{
"id": "e4d022b5c61f5dccc30502fe74c24e7998960a4bc6c89c942ac413c74ccb24ac",
"pubkey": "9bddd4578b658620bdbf06f97fb8f978c08b641d1d0248a613f552d7ef7f709a",
"created_at": 1727727266,
"kind": 1,
"tags": [
[
"proxy",
"https://mastodon.social/users/helge/statuses/113228334114876335",
"activitypub"
]
],
"content": "I'm thinking about how to do SwiftWebUI in a useful way. A big thing in web is state handling, i.e. what would `@State` mean? In SwiftWebUI/WO this is just part of an in-server, sticky, session. Which is almost never what you want (and probably shouldn't be a convenience default).\nSome state could be in a parameter, or a cookie, or an actual session, or in Redis.\nBut having the way of state handling part of the View feels a little icky, too tightly scoped.\n\nhttps://files.mastodon.social/media_attachments/files/113/228/333/258/352/918/original/cff26736866b0071.png",
"sig": "44bc7d5a172c49b6beb116e7d4680838882ea92d0451c389333dc7522a029366e136662ea534e1cac6ac7b24db9e1185df6e55eff03e15abdd3ca769487afd1c"
}