New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

tcg-logger

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tcg-logger - npm Package Compare versions

Comparing version

to
1.0.1

6

index.js
/**
* TCG Logger
*
* @exports a singleton Bunyan log instance for logging use
* Class for creating a Bunyan logger with some added goodies
*/

@@ -62,3 +62,3 @@

class Logger extends Bunyan {
constructor({logStream = 'debug', logFile = ''} = {}) {
constructor({logStream = 'debug', logFile = '', logName = 'TCG Logger'} = {}) {
// Add streams based on config

@@ -85,3 +85,3 @@ const consoleDebugStream = {

super({
name: 'TCG Logger',
name: logName,
streams: logStreams,

@@ -88,0 +88,0 @@ serializers: {

{
"name": "tcg-logger",
"version": "1.0.0",
"version": "1.0.1",
"description": "Bunyan Logger for TCG apps",
"keywords": [
"log",
"json",
"logger",
"middleware"
],
"keywords": [
"log",
"json",
"logger",
"middleware"
],
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"files": [
"index.js"
],
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"files": [
"index.js"
],
"author": "Joe Furfaro",
"license": "MIT",
"engines": {
"node": ">=7.0"
},
"license": "MIT",
"repository": {
"type": "git",
"url": "https://github.com/the-control-group/tcg-logger-express.git"
},
"engines": {
"node": ">=7.0"
},
"dependencies": {

@@ -24,0 +28,0 @@ "bunyan": "^1.8.5",

@@ -1,2 +0,2 @@

# TCG Express Logger Module
# TCG Logger Module for Express

@@ -26,5 +26,11 @@ Built on [Bunyan](https://github.com/trentm/node-bunyan). Built-in Express middleware includes appending a child logger to each request and response times.

const log = new Logger({
logStream: <'debug', 'json', or false>, // Debug for human readable logs to stdout, false to disable stdout, and json for ...well... json
logFile: '/absolute/path/to/logfile' // Pass a string absolute path for logging to a file, leave empty to disable
// Debug for human readable logs to stdout, false to disable stdout, and json for ...well... json
logStream: <'debug', 'json', or false>,
// Pass a string absolute path for logging to a file, leave empty to disable
logFile: '/absolute/path/to/logfile',
// Name to give the logger
logName: 'TCG Logger'
});
```