mirror of
https://github.com/avatao-content/frontend-tutorial-framework
synced 2024-12-05 02:11:32 +00:00
Make ProcessLogService.newLog a BehaviorSubject
This commit is contained in:
parent
188b3a9631
commit
fc10db6cac
@ -41,7 +41,11 @@ export const config = {
|
||||
route: 'console',
|
||||
defaultContent: '',
|
||||
rewriteContentWithProcessLogs: 'stdout',
|
||||
showLiveLogs: true
|
||||
showLiveLogs: true,
|
||||
defaultLogs: {
|
||||
stdout: '',
|
||||
stderr: ''
|
||||
}
|
||||
},
|
||||
testmessenger: {
|
||||
route: 'testmessenger'
|
||||
|
@ -3,13 +3,13 @@
|
||||
|
||||
import { Injectable } from '@angular/core';
|
||||
import { WebSocketService } from './websocket.service';
|
||||
import { Subject } from 'rxjs/Subject';
|
||||
import { ProcessLogCommand } from './processlog-command';
|
||||
import { config } from '../config';
|
||||
import { BehaviorSubject } from 'rxjs/BehaviorSubject';
|
||||
|
||||
@Injectable()
|
||||
export class ProcessLogService {
|
||||
newLog = new Subject<any>();
|
||||
newLog = new BehaviorSubject<any>(config.console.defaultLogs);
|
||||
showLiveLogs = config.console.showLiveLogs;
|
||||
|
||||
command_handlers = {
|
||||
|
Loading…
Reference in New Issue
Block a user