log for GoJS
set log config in env.yml
log:
level: info # specify the log level (error/warning/info/debug), default: info
file: out.log # specify the log file, default logs to standard output
splitTag: 20060102 # log file split format, refer to Golang date time format syntax, default does not split
sensitive: phone,password,secret,token,accessToken # fields to be desensitized in logs, separated by commas. The matching values in requests, responses, HTTP headers, and request/response JSON data indices will be desensitized
example
import log from 'apigo.cc/gojs/log'
log.info('hello world')
log.error('some error', {name: 'abc'})
module.exports
function debug(message:string, info?:Object): void {}
function info(message:string, info?:Object): void {}
function warn(message:string, info?:Object): void {}
function error(message:string, info?:Object): void {}
full api see log.ts