From 461b8cd38ccbe5f4f274b6bc667614cdff74b278 Mon Sep 17 00:00:00 2001 From: cebgcontract <99630598+cebgcontract@users.noreply.github.com> Date: Wed, 2 Mar 2022 13:52:28 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9prerender-spa-plugin=E9=85=8D?= =?UTF-8?q?=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- vue.config.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/vue.config.js b/vue.config.js index c8ad1e3..43d4421 100644 --- a/vue.config.js +++ b/vue.config.js @@ -1,5 +1,6 @@ const path = require('path') const PrerenderSPAPlugin = require('prerender-spa-plugin') +const Renderer = PrerenderSPAPlugin.PuppeteerRenderer const name = 'CEBG' @@ -39,7 +40,14 @@ module.exports = { new PrerenderSPAPlugin({ indexPath: path.resolve('dist/index.html'), staticDir: path.resolve('dist'), - routes: ['/nft', '/gameplay', '/tokenomic', '/roadmap', '/team'] + routes: ['/', '/nft', '/gameplay', '/tokenomic', '/roadmap', '/team'], + renderer: new Renderer({ + headless: true, + defaultViewport: { + width: 1920, + height: 1080 + } + }) }) ) }