From 0148a29e922a142c1c6f43b50890c307cb9381bf Mon Sep 17 00:00:00 2001 From: liudongqi Date: Wed, 4 Sep 2024 18:55:00 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=20=20nodejs=20request=20enti?= =?UTF-8?q?ty=20too=20large?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app.js b/app.js index b7f5e5c..1d0bda2 100644 --- a/app.js +++ b/app.js @@ -16,7 +16,7 @@ const app = express(); /* 配置框架环境 S */ // 设置 express 的中间件 body-parser -app.use(bodyParser.json()); +app.use(bodyParser.json('10mb')); app.use(bodyParser.urlencoded({extended: true})); // 设置 public 为静态文件的存放文件夹