diff --git a/plugins/armcordSettings/index.js b/plugins/armcordSettings/index.js
index 3d5f0f3..baa0932 100644
--- a/plugins/armcordSettings/index.js
+++ b/plugins/armcordSettings/index.js
@@ -2,7 +2,9 @@ import { LegacyPage } from "./pages/LegacyPage";
import { SettingsPage } from "./pages/SettingsPage";
import { ThemesPage } from "./pages/ThemesPage";
import { UpdaterPage } from "./pages/UpdaterPage";
+import { refreshSettings } from "./settings";
const {
+ plugin: {store},
settings: {registerSection},
util: { log },
} = shelter;
@@ -17,6 +19,7 @@ let settingsPages = [
]
export function onLoad() {
+ refreshSettings()
log("ArmCord Settings")
settingsPages
}
diff --git a/plugins/armcordSettings/pages/SettingsPage.jsx b/plugins/armcordSettings/pages/SettingsPage.jsx
index d43e6db..e31ad83 100644
--- a/plugins/armcordSettings/pages/SettingsPage.jsx
+++ b/plugins/armcordSettings/pages/SettingsPage.jsx
@@ -1,21 +1,19 @@
-
+import { set } from "../settings";
const {
plugin: { store },
ui: { SwitchItem, Header, Divider, HeaderTags },
} = shelter;
-export async function SettingsPage() {
- const settings = armcord.settings.config
- console.error(settings)
+export function SettingsPage() {
return(
<>
- ArmCord CSP
- Vencord
+ set("armcordCSP", e)}>ArmCord CSP
+ Vencord
>
)
}
diff --git a/plugins/armcordSettings/settings.js b/plugins/armcordSettings/settings.js
new file mode 100644
index 0000000..5ba3251
--- /dev/null
+++ b/plugins/armcordSettings/settings.js
@@ -0,0 +1,9 @@
+const {plugin: { store }} = shelter
+export function refreshSettings() {
+ store.settings = window.armcord.settings.config
+ console.log(store.settings)
+}
+export function set(key, value) {
+ armcord.settings.setConfig(key, value)
+ refreshSettings()
+}
\ No newline at end of file