Pinia Persistent Storage via AT Protocol for Open Web Desktop

refactor: Rename module and plugin, move config to /runtime

dxlliv 997c90af af92a0b2

+7 -5
+4 -1
index.ts module.ts
··· 7 7 setup() { 8 8 const {resolve} = createResolver(import.meta.url); 9 9 10 - addPlugin(resolve('./runtime/plugins/pluginPiniaAtproto.ts')) 10 + addPlugin({ 11 + src: resolve('./runtime/plugin'), 12 + mode: 'client' 13 + }) 11 14 } 12 15 })
+3 -4
runtime/plugins/pluginPiniaAtproto.ts runtime/plugin.ts
··· 4 4 import {defineNuxtPlugin, useNuxtApp} from "nuxt/app" 5 5 import {toRaw} from "vue" 6 6 import {usePinia} from "#imports" 7 - import * as localforage from 'localforage' 7 + import localforage from 'localforage' 8 8 import { 9 9 getAtprotoApplicationState, 10 10 putAtprotoApplicationState, 11 11 listAtprotoApplicationStateRecords, parseAtprotoStoreKey 12 - } from "../utils/utilAtprotoApplications"; 13 - 12 + } from "./utils/utilAtprotoApplications"; 14 13 15 14 function shouldSyncWithATProto( 16 15 piniaStoreKey: string, ··· 112 111 }), 113 112 ) 114 113 } 115 - }) 114 + })