Merge branch 'frontend-core-ts-2' of github.com:Budibase/budibase into ts-portal-admin-store

This commit is contained in:
Andrew Kingston 2024-12-12 14:53:48 +00:00
commit ce3a479590
No known key found for this signature in database
2 changed files with 4 additions and 8 deletions

View File

@ -2,13 +2,13 @@ import { writable } from "svelte/store"
type GotoFuncType = (path: string) => void
interface Store {
interface PortalNavigationStore {
initialisated: boolean
goto: GotoFuncType
}
export function createNavigationStore() {
const store = writable<Store>({
const store = writable<PortalNavigationStore>({
initialisated: false,
goto: undefined as any,
})

View File

@ -1,17 +1,13 @@
import { writable } from "svelte/store"
import { PluginSource } from "constants/index"
import { Plugin } from "@budibase/types"
import { API } from "api"
interface Plugin {
_id: string
}
export function createPluginsStore() {
const { subscribe, set, update } = writable<Plugin[]>([])
async function load() {
const plugins = await API.getPlugins()
const plugins = (await API.getPlugins()) as Plugin[]
set(plugins)
}