move log to util.js
This commit is contained in:
parent
267ddc890f
commit
5cae7b9658
|
@ -1,18 +1,10 @@
|
||||||
import React, { Component } from 'react';
|
import React, { Component } from 'react';
|
||||||
|
|
||||||
|
import './App.css';
|
||||||
import Service from './Service.js';
|
import Service from './Service.js';
|
||||||
import ServicePlaceholder from './ServicePlaceholder.js';
|
import ServicePlaceholder from './ServicePlaceholder.js';
|
||||||
import './App.css';
|
|
||||||
import OP from './ws/op.js';
|
import OP from './ws/op.js';
|
||||||
|
import { log } from './util.js';
|
||||||
const log = (...args) => {
|
|
||||||
console.log(
|
|
||||||
'%c[elstat]%c',
|
|
||||||
'color: purple; font-weight: bold',
|
|
||||||
'color: inherit; font-weight: inherit',
|
|
||||||
...args,
|
|
||||||
);
|
|
||||||
};
|
|
||||||
|
|
||||||
const DOMAIN = 'https://elstatus.stayathomeserver.club';
|
const DOMAIN = 'https://elstatus.stayathomeserver.club';
|
||||||
// const ENDPOINT = 'http://localhost:8069/api/status'
|
// const ENDPOINT = 'http://localhost:8069/api/status'
|
||||||
|
|
|
@ -0,0 +1,8 @@
|
||||||
|
export function log(...args) {
|
||||||
|
console.log(
|
||||||
|
'%c[elstat]%c',
|
||||||
|
'color: purple; font-weight: bold',
|
||||||
|
'color: inherit; font-weight: inherit',
|
||||||
|
...args,
|
||||||
|
);
|
||||||
|
}
|
Loading…
Reference in New Issue