Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
open-webui
Commits
f5bca7c4
Commit
f5bca7c4
authored
Oct 18, 2023
by
Timothy J. Baek
Browse files
Update +page.svelte
parent
36b3ec94
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletion
+7
-1
src/routes/+page.svelte
src/routes/+page.svelte
+7
-1
No files found.
src/routes/+page.svelte
View file @
f5bca7c4
...
@@ -12,11 +12,12 @@
...
@@ -12,11 +12,12 @@
import { openDB, deleteDB } from 'idb';
import { openDB, deleteDB } from 'idb';
import { ENDPOINT as SERVER_ENDPOINT } from '$lib/contants';
import { ENDPOINT as SERVER_ENDPOINT } from '$lib/contants';
import Error from './+error.svelte';
export let data: PageData;
export let data: PageData;
$: ({ models, OLLAMA_ENDPOINT } = data);
$: ({ models, OLLAMA_ENDPOINT } = data);
const ENDPOINT = OLLAMA_ENDPOINT ? OLLAMA_ENDPOINT : SERVER_
ENDPOINT;
let
ENDPOINT;
let textareaElement;
let textareaElement;
let db;
let db;
...
@@ -31,6 +32,11 @@
...
@@ -31,6 +32,11 @@
let messages = [];
let messages = [];
onMount(async () => {
onMount(async () => {
ENDPOINT = OLLAMA_ENDPOINT ? OLLAMA_ENDPOINT : SERVER_ENDPOINT;
console.log(OLLAMA_ENDPOINT);
console.log(SERVER_ENDPOINT);
console.log(ENDPOINT);
let settings = localStorage.getItem('settings');
let settings = localStorage.getItem('settings');
if (settings) {
if (settings) {
settings = JSON.parse(settings);
settings = JSON.parse(settings);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment