first commit
This commit is contained in:
commit
db5762abd4
687 files changed
+171307
No files matched your search
@@ -0,0 +1,17 @@
|
||||
import { defineNuxtPlugin } from "#app";
|
||||
import { useAuth, useApi } from "~/lib/auth.js";
|
||||
import { t as useSiteConfig } from "~/lib/useSiteConfig.js";
|
||||
import { t as useNavigation } from "~/lib/navigation-state.js";
|
||||
|
||||
export default defineNuxtPlugin({
|
||||
name: "console-bootstrap",
|
||||
dependsOn: ["console-ui"],
|
||||
async setup() {
|
||||
const auth = useAuth();
|
||||
const tasks = [useSiteConfig().load()];
|
||||
if (auth.isLoggedIn && window.location.pathname !== "/home.htm") {
|
||||
tasks.push(useNavigation(auth, useApi()).load(), auth.fetchOverview());
|
||||
}
|
||||
await Promise.allSettled(tasks);
|
||||
},
|
||||
});
|
||||
Reference in new issue
Block a user