diff options
author | Paul Frazee <pfrazee@gmail.com> | 2023-03-21 12:59:10 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-21 12:59:10 -0500 |
commit | 858d4c8c8811ca8e16bffe3bfe0d541e576177ec (patch) | |
tree | 8199e1029edb7161c34fb59806399c30fcdd61a3 /src/state/models/root-store.ts | |
parent | c1d454b7cfe6a7ec107b39483df9cb0fb64e1c76 (diff) | |
download | voidsky-858d4c8c8811ca8e16bffe3bfe0d541e576177ec.tar.zst |
* Introduce an image sizes cache to improve feed layouts (close #213) * Clear out resolved promises from the image cache
Diffstat (limited to 'src/state/models/root-store.ts')
-rw-r--r-- | src/state/models/root-store.ts | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/state/models/root-store.ts b/src/state/models/root-store.ts index 03550f1b0..4a8d09b41 100644 --- a/src/state/models/root-store.ts +++ b/src/state/models/root-store.ts @@ -13,10 +13,11 @@ import {LogModel} from './log' import {SessionModel} from './session' import {ShellUiModel} from './ui/shell' import {ProfilesViewModel} from './profiles-view' -import {LinkMetasViewModel} from './link-metas-view' +import {LinkMetasCache} from './cache/link-metas' import {NotificationsViewItemModel} from './notifications-view' import {MeModel} from './me' import {resetToTab} from '../../Navigation' +import {ImageSizesCache} from './cache/image-sizes' export const appInfo = z.object({ build: z.string(), @@ -34,7 +35,8 @@ export class RootStoreModel { shell = new ShellUiModel(this) me = new MeModel(this) profiles = new ProfilesViewModel(this) - linkMetas = new LinkMetasViewModel(this) + linkMetas = new LinkMetasCache(this) + imageSizes = new ImageSizesCache() // HACK // this flag is to track the lexicon breaking refactor |