Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
小 白蛋
Nocobase
Commits
ff7757bf
Commit
ff7757bf
authored
3 years ago
by
chenos
Browse files
Options
Download
Email Patches
Plain Diff
fix: remove compress middleware
parent
29d386a6
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
packages/plugin-client/src/server.ts
+0
-14
packages/plugin-client/src/server.ts
with
0 additions
and
14 deletions
+0
-14
packages/plugin-client/src/server.ts
+
0
-
14
View file @
ff7757bf
...
...
@@ -2,7 +2,6 @@ import path from 'path';
import
send
from
'
koa-send
'
;
import
serve
from
'
koa-static
'
;
import
{
PluginOptions
}
from
'
@nocobase/server
'
;
import
compress
from
'
koa-compress
'
;
export
default
{
name
:
'
client
'
,
...
...
@@ -11,19 +10,6 @@ export default {
if
(
root
&&
!
root
.
startsWith
(
'
/
'
))
{
root
=
path
.
resolve
(
process
.
cwd
(),
root
);
}
this
.
app
.
use
(
compress
({
// filter (content_type) {
// return /text/i.test(content_type)
// },
threshold
:
20480
,
// gzip: {
// flush: require('zlib').constants.Z_SYNC_FLUSH
// },
// deflate: {
// flush: require('zlib').constants.Z_SYNC_FLUSH,
// },
// br: false // disable brotli
}));
this
.
app
.
middleware
.
unshift
(
async
(
ctx
,
next
)
=>
{
if
(
!
root
)
{
return
next
();
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Projects
Groups
Snippets
Help