1 import { isBrowser } from './utils';
3 const host = isBrowser() ? window.location.hostname : 'localhost';
4 const secure = isBrowser() && window.location.protocol == 'https:' ? 's' : '';
5 const port = isBrowser()
6 ? window.location.port == '1234'
10 const endpoint = `${host}:${port}`;
12 export const wsUri = `ws${secure}://${endpoint}/api/v1/ws`;
13 export const httpUri = `http${secure}://${endpoint}/api/v1`;