PABLOF7z on Nostr: omg! we have someone that actually knows svelte in nostr???! if I could follow you ...
omg! we have someone that actually knows svelte in nostr???!
if I could follow you more I would, but FOLLOWED!
what always trips me is the reactivity gotchas, I get the `a = a` when you want to trigger reactivity on an array/object, but sometimes I get weirdness with the reactivity beyond that.
For example, I have a /a/[naddr]/+page.svelte that just renders a <List {naddr> />
Is wrapping the <List {naddr} /> in a {#key naddr} the right way? Without the #key svelte wouldn't react to page changes with re-rendering the <List even though the {naddr} was changing
----
I'll probably run into other svelte weirdness without the next hour 😂 I'll add another response if that's cool 😀
Published at
2023-07-12 14:58:09Event JSON
{
"id": "18ad5ca194257bae4a1b4a7d055c1f6a87b09d4c3b1c025e7a50637d15909ffb",
"pubkey": "fa984bd7dbb282f07e16e7ae87b26a2a7b9b90b7246a44771f0cf5ae58018f52",
"created_at": 1689173889,
"kind": 1,
"tags": [
[
"e",
"a0890e16302aeb018feccf36fb1b4f7396b6489c25dc5865ceadf1e2e5408b3d",
"",
"root"
],
[
"e",
"ccb3ffe946a464dcc4f60b156ced51dba56585a858748a11031a1eb03527bb05",
"wss://nos.lol/",
"reply"
],
[
"p",
"7e9c924ae5255c95a454d28ae89552a1e081f828ad4dc0381508b509188c865e"
],
[
"t",
"key"
],
[
"t",
"key"
]
],
"content": "omg! we have someone that actually knows svelte in nostr???!\n\nif I could follow you more I would, but FOLLOWED!\n\nwhat always trips me is the reactivity gotchas, I get the `a = a` when you want to trigger reactivity on an array/object, but sometimes I get weirdness with the reactivity beyond that.\n\nFor example, I have a /a/[naddr]/+page.svelte that just renders a \u003cList {naddr\u003e /\u003e\n\nIs wrapping the \u003cList {naddr} /\u003e in a {#key naddr} the right way? Without the #key svelte wouldn't react to page changes with re-rendering the \u003cList even though the {naddr} was changing\n\n----\n\nI'll probably run into other svelte weirdness without the next hour 😂 I'll add another response if that's cool 😀",
"sig": "02c665e8d3b056e733c7c95033503c5b9be9cc0e2be7633d0249cbfa2a8396b8f4b22960605c4deb30f66df1d3093222418e81b39431fa5b94fd3b0530f92b73"
}