chore: update the base url of the plugin resources

Signed-off-by: Ryan Wang <i@ryanc.cc>
pull/591/head
Ryan Wang 2022-07-25 10:41:24 +08:00
parent 07ac270890
commit 3515108cab
3 changed files with 4 additions and 4 deletions

View File

@ -117,7 +117,7 @@ async function loadPluginModules() {
if (entry) {
const { load } = useScriptTag(
`http://localhost:8090${plugin.status?.entry}`
`${import.meta.env.VITE_API_URL}${plugin.status?.entry}`
);
await load();
const pluginModule = window[plugin.metadata.name];
@ -131,7 +131,7 @@ async function loadPluginModules() {
if (stylesheet) {
try {
await loadStyle(`http://localhost:8090${stylesheet}`);
await loadStyle(`${import.meta.env.VITE_API_URL}${stylesheet}`);
} catch (e) {
console.error(e);
}

View File

@ -151,7 +151,7 @@ onMounted(() => {
<iframe
:class="iframeClasses"
class="border-none transition-all duration-300"
src="http://localhost:8090"
src="https://halo.run"
></iframe>
</div>
</div>

View File

@ -41,7 +41,7 @@ const handleLogin = async () => {
try {
loginForm.value.logging = true;
await fetch("http://localhost:8090/login", {
await fetch(`${import.meta.env.VITE_API_URL}/login`, {
method: "POST",
headers: {
"Content-Type": "application/x-www-form-urlencoded",