Switch to pnpm, use new welshman stuff
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
import {page} from "$app/stores"
|
||||
import {ago, MONTH} from "@welshman/lib"
|
||||
import {GROUPS, THREAD, COMMENT, MESSAGE, DELETE} from "@welshman/util"
|
||||
import {subscribe, load} from "@welshman/app"
|
||||
import {request, load} from "@welshman/net"
|
||||
import Page from "@lib/components/Page.svelte"
|
||||
import SecondaryNav from "@lib/components/SecondaryNav.svelte"
|
||||
import MenuSpace from "@app/components/MenuSpace.svelte"
|
||||
@@ -56,7 +56,7 @@
|
||||
|
||||
// Load all groups for this space to populate navigation. It would be nice to sync, but relay29
|
||||
// is too picky about how requests are built.
|
||||
load({relays, filters: [{kinds: [GROUPS]}], delay: 0})
|
||||
load({relays, filters: [{kinds: [GROUPS]}]})
|
||||
|
||||
// Load threads, comments, and recent messages for user rooms to help with a quick page transition
|
||||
pullConservatively({
|
||||
@@ -69,10 +69,10 @@
|
||||
})
|
||||
|
||||
// Listen for deletes that would apply to messages we already have, and new groups
|
||||
const sub = subscribe({relays, filters: [{kinds: [DELETE, GROUPS], since}]})
|
||||
const req = request({relays, filters: [{kinds: [DELETE, GROUPS], since}]})
|
||||
|
||||
return () => {
|
||||
sub.close()
|
||||
req.close()
|
||||
}
|
||||
})
|
||||
</script>
|
||||
|
||||
@@ -3,7 +3,8 @@
|
||||
import {page} from "$app/stores"
|
||||
import {sortBy, sleep} from "@welshman/lib"
|
||||
import {COMMENT, getTagValue} from "@welshman/util"
|
||||
import {repository, subscribe} from "@welshman/app"
|
||||
import {request} from "@welshman/net"
|
||||
import {repository} from "@welshman/app"
|
||||
import {deriveEvents} from "@welshman/store"
|
||||
import Icon from "@lib/components/Icon.svelte"
|
||||
import PageBar from "@lib/components/PageBar.svelte"
|
||||
@@ -45,10 +46,10 @@
|
||||
let showReply = $state(false)
|
||||
|
||||
onMount(() => {
|
||||
const sub = subscribe({relays: [url], filters})
|
||||
const req = request({relays: [url], filters})
|
||||
|
||||
return () => {
|
||||
sub.close()
|
||||
req.close()
|
||||
setChecked($page.url.pathname)
|
||||
}
|
||||
})
|
||||
|
||||
@@ -3,7 +3,8 @@
|
||||
import {page} from "$app/stores"
|
||||
import {sortBy, sleep} from "@welshman/lib"
|
||||
import {COMMENT, getTagValue} from "@welshman/util"
|
||||
import {repository, subscribe} from "@welshman/app"
|
||||
import {repository} from "@welshman/app"
|
||||
import {request} from "@welshman/net"
|
||||
import {deriveEvents} from "@welshman/store"
|
||||
import Icon from "@lib/components/Icon.svelte"
|
||||
import PageBar from "@lib/components/PageBar.svelte"
|
||||
@@ -42,10 +43,10 @@
|
||||
let showReply = $state(false)
|
||||
|
||||
onMount(() => {
|
||||
const sub = subscribe({relays: [url], filters})
|
||||
const req = request({relays: [url], filters})
|
||||
|
||||
return () => {
|
||||
sub.close()
|
||||
req.close()
|
||||
setChecked($page.url.pathname)
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user