Closed artemyarulin closed 9 years ago
OK, I found two reasons for that:
1) CDN url was outdated (it was pointing to v.0.0.6) (see #61 )
2) replaceLoggingMethods
has to be called after log.methodFactory
replacement. The easiest way is to make a call through setLevel
function. I'm not sure - it this a bug or expected behavior? If yes - it should be mentioned in README
Thanks
Ah, nice spot, yes. I think I must've been calling setLevel myself when I set that up. Would you be up for updating the docs to cover this?
An alternative solution where we add a setter or something for methodFactory which automatically rebuilds the logging methods would be fine too, but probably trickier.
Great - I'll create a pull request. On a side note - do you have somewhere list of loglevel plugins? I'm thinking of creating one (to send logs to the server), maybe it exists already?
Not yet; the plugin API was only added relatively recently, and I think this would be the first. Very happy to add one to the README though.
Cool to be the first one :) Here the loglevel-serverSend, works for me and with your project my development life became a little bit easier, thanks again!
Hi, thank you for your project.
Maybe I'm missing something but I cannot get your example plugin from readme working. It should add prefix for each log level, but at the end it does nothing. Here jsfiddle
Doesn't work in latest Chrome