From 4757836a67c58e2dfe2d1dce645e69399dc92b5b Mon Sep 17 00:00:00 2001 From: Tomas Roos Date: Fri, 9 Mar 2018 12:23:21 +0100 Subject: [PATCH] Expose manifest.js.map during development (#3975) --- server/index.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/server/index.js b/server/index.js index c9e4c3f6..49196374 100644 --- a/server/index.js +++ b/server/index.js @@ -166,6 +166,14 @@ export default class Server { await this.serveStatic(req, res, p) }, + '/_next/:buildId/manifest.js.map': async (req, res, params) => { + if (!this.dev) return this.send404(res) + + this.handleBuildId(params.buildId, res) + const p = join(this.dir, this.dist, 'manifest.js.map') + await this.serveStatic(req, res, p) + }, + '/_next/:buildId/main.js': async (req, res, params) => { if (this.dev) { this.handleBuildId(params.buildId, res)