mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 10:45:47 +00:00
feature(server) add compress: speed up client side load
This commit is contained in:
parent
ce8eea7b78
commit
b083de710b
1 changed files with 3 additions and 0 deletions
|
|
@ -9,6 +9,7 @@ const currify = require('currify');
|
|||
const squad = require('squad');
|
||||
const tryToCatch = require('try-to-catch');
|
||||
const wraptile = require('wraptile');
|
||||
const compression = require('compression');
|
||||
|
||||
const two = currify((f, a, b) => f(a, b));
|
||||
const exit = require(DIR_SERVER + 'exit');
|
||||
|
|
@ -52,6 +53,8 @@ module.exports = async (options, config) => {
|
|||
path: `${prefix}/socket.io`,
|
||||
});
|
||||
|
||||
app.use(compression());
|
||||
|
||||
app.use(prefix, cloudcmd({
|
||||
config: options,
|
||||
socket: socketServer,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue