Added server

This commit is contained in:
Myx
2022-01-02 01:26:38 +01:00
parent a0aef9e2c8
commit a30d6b2d63
293 changed files with 3337 additions and 5 deletions

View File

@@ -0,0 +1,28 @@
import { AddressStorageKey, PortStorageKey, ProtocolStorageKey } from "../gotobed.models";
export const storeName = 'Gotobed';
export interface GotobedState {
command: string;
isLoading: boolean;
protocol: string;
port: string;
address: string;
isConnected: boolean;
}
export const initialGotoBedState: GotobedState = {
command: '',
isLoading: false,
protocol: localStorage.getItem(ProtocolStorageKey) ?? "http",
port: localStorage.getItem(PortStorageKey) ?? '3000',
address: localStorage.getItem(AddressStorageKey) ?? 'localhost:8080',
isConnected: false,
};
export interface LoadSettingsState {
protocol: string;
port: string;
address: string;
}