fedwiki / wiki-server

Federated Wiki client and server in Node.js
Other
153 stars 35 forks source link

Feat: color coding per site in request logger #191

Closed almereyda closed 1 month ago

almereyda commented 2 months ago

This is the first half of the implementation of #190 proposed by Ward.

This mingles three StackOverflow answers and converts them to CoffeeScript.

It will colour requests in regular and in farm mode. Both escape the hostname. Eventually we will want to consider removing the :vhost token from the logger in regular single-site wikis.

addresses #190

almereyda commented 2 months ago

Proof:

grafik

almereyda commented 1 month ago

Please let me know if this meets our coding standards. I have the intuition that the colorString method could be refactored to live in some other place and be imported as a module from there.

If this is supposed to be a plugin, I can also try to rework it.

paul90 commented 1 month ago

Looks good. Thanks.