feat: add compression to l-s
This commit is contained in:
parent
e6e45ec509
commit
9ccdd7d6f9
3 changed files with 126 additions and 9 deletions
|
|
@ -1,5 +1,6 @@
|
|||
'use strict'
|
||||
|
||||
const compression = require('compression')
|
||||
const morgan = require('morgan')
|
||||
const helmet = require('helmet')
|
||||
const bodyParser = require('body-parser')
|
||||
|
|
@ -365,6 +366,7 @@ const configRequiredRoutes = [
|
|||
const app = express()
|
||||
const localApp = express()
|
||||
|
||||
app.use(compression({ threshold: 500 }))
|
||||
app.use(helmet({ noCache: true }))
|
||||
app.use(bodyParser.json({ limit: '2mb' }))
|
||||
app.use(morgan('dev', { skip, stream: logger.stream }))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue