perf: Performance work, add PWA

This commit is contained in:
Jesse Wierzbinski 2024-05-11 21:30:02 -10:00
parent 7d07e639c8
commit 6e8f4ae8e1
No known key found for this signature in database
19 changed files with 76 additions and 45 deletions

View file

@ -1,14 +1,14 @@
<template>
<ClientOnly>
<div v-if="loaded" :defer="true" class="mx-auto max-w-2xl w-full pb-72">
<SocialElementsNotesNote v-for="note of context?.ancestors" :note="note" />
<LazySocialElementsNotesNote v-for="note of context?.ancestors" :note="note" />
<div ref="element" class="first:rounded-t last:rounded-b overflow-hidden">
<SocialElementsNotesNote class="!rounded-none border-2 border-pink-500" v-if="note" :note="note" />
<LazySocialElementsNotesNote class="!rounded-none border-2 border-pink-500" v-if="note" :note="note" />
</div>
<SocialElementsNotesNote v-for="note of context?.descendants" :note="note" />
<LazySocialElementsNotesNote v-for="note of context?.descendants" :note="note" />
</div>
<div :defer="true" v-else class="mx-auto max-w-2xl w-full overflow-y-auto">
<SocialElementsNotesNote v-for="_ of 5" :skeleton="true" />
<div v-else class="mx-auto max-w-2xl w-full overflow-y-auto">
<LazySocialElementsNotesNote v-for="_ of 5" :skeleton="true" />
</div>
</ClientOnly>
</template>

View file

@ -1,9 +1,9 @@
<template>
<div class="mx-auto max-w-2xl w-full">
<TimelinesTimelineScroller>
<SocialElementsUsersAccount :account="account ?? undefined" />
<TimelinesAccount :id="accountId" :key="accountId" />
</TimelinesTimelineScroller>
<LazyTimelinesTimelineScroller>
<LazySocialElementsUsersAccount :account="account ?? undefined" />
<LazyTimelinesAccount :id="accountId" :key="accountId" />
</LazyTimelinesTimelineScroller>
</div>
</template>