Update npm dependencies

This commit is contained in:
Annika Backstrom 2019-12-14 14:20:18 -05:00
parent 684eb1448b
commit 154adef5ba
5 changed files with 505 additions and 2033 deletions

View File

@ -3,8 +3,8 @@
// TODO: These should really be their own individual classes. Are // TODO: These should really be their own individual classes. Are
// there enough commonalities to warrant a base class? // there enough commonalities to warrant a base class?
const spawn = require('child_process').spawn; const { spawn } = require('child_process');
const EventEmitter = require('events').EventEmitter; const { EventEmitter } = require('events');
module.exports.ChildProcessEmitter = class ChildProcessEmitter extends EventEmitter { module.exports.ChildProcessEmitter = class ChildProcessEmitter extends EventEmitter {
constructor(command, logger) { constructor(command, logger) {

View File

@ -2,9 +2,9 @@
const tags = require('./library/tags'); const tags = require('./library/tags');
const throttle = require('throttle-debounce/throttle'); const { throttle } = require('throttle-debounce');
const ChildProcessEmitter = require('./child-process').ChildProcessEmitter; const { ChildProcessEmitter } = require('./child-process');
const DEFAULT_STOP_THROTTLE = 2000; const DEFAULT_STOP_THROTTLE = 2000;
const DEFAULT_PAUSE_THROTTLE = 2000; const DEFAULT_PAUSE_THROTTLE = 2000;

2491
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -1,29 +1,33 @@
{ {
"name": "rfid", "name": "pi-rfid-jukebox",
"version": "1.0.0", "version": "1.0.1",
"description": "", "description": "",
"main": "player.js", "main": "player.js",
"repository": {
"type": "git",
"url": "https://git.abackstrom.com/annika/pi-rfid-jukebox"
},
"scripts": { "scripts": {
"build-css": "stylus source/stylesheets/index.styl -o static/css", "build-css": "stylus source/stylesheets/index.styl -o static/css",
"watch-css": "stylus source/stylesheets/index.styl -o static/css -w", "watch-css": "stylus source/stylesheets/index.styl -o static/css -w",
"clean": "rm -rf static/css && mkdir -p static/css", "clean": "rm -rf static/css && mkdir -p static/css",
"build": "npm run clean && npm run build-css", "build": "npm run clean && npm run build-css",
"watch": "npm run clean && npm run watch-css & nodemon player -e js,jade", "watch": "npm run clean && npm run watch-css && nodemon player -e js,jade",
"start": "node player" "start": "node player"
}, },
"author": "", "author": "Annika Backstrom",
"license": "ISC", "license": "ISC",
"dependencies": { "dependencies": {
"body-parser": "^1.17.1", "body-parser": "^1.19.0",
"express": "^4.14.0", "bufferutil": "^4.0.1",
"glob": "^7.1.1", "express": "^4.17.1",
"glob": "^7.1.6",
"morgan": "^1.7.0", "morgan": "^1.7.0",
"mustache": "^2.3.0", "mustache": "^3.1.0",
"throttle-debounce": "^1.0.1", "nodemon": "^2.0.2",
"winston": "^2.3.1", "throttle-debounce": "^2.1.0",
"ws": "^2.2.2" "utf-8-validate": "^5.0.2",
}, "winston": "^3.2.1",
"devDependencies": { "ws": "^7.2.1"
"nodemon": "^1.11.0"
} }
} }

View File

@ -10,11 +10,12 @@ const MediaLibrary = new library.Library(config, MediaLibraryFileBackend);
const express = require('express'); const express = require('express');
const morgan = require('morgan') const morgan = require('morgan')
const winston = require('winston');
var logger = new (winston.Logger)({ const { createLogger, format, transports } = require('winston');
var logger = createLogger({
transports: [ transports: [
new (winston.transports.Console)() new transports.Console()
] ]
}); });