Initial commit 🍀
This commit is contained in:
commit
b3f42e62af
405 changed files with 31017 additions and 0 deletions
18
src/web/app/common/scripts/log.ls
Normal file
18
src/web/app/common/scripts/log.ls
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
riot = require \riot
|
||||
|
||||
logs = []
|
||||
|
||||
ev = riot.observable!
|
||||
|
||||
function log(msg)
|
||||
logs.push do
|
||||
date: new Date!
|
||||
message: msg
|
||||
ev.trigger \log
|
||||
|
||||
riot.mixin \log do
|
||||
logs: logs
|
||||
log: log
|
||||
log-event: ev
|
||||
|
||||
module.exports = log
|
||||
Loading…
Add table
Add a link
Reference in a new issue