Differences between vue-router configuration development environment and production environment

whether vue-router can be configured, or whether vue-router can be dynamically configured using webpack to meet the requirements:
1. All routes are available through one configuration of the json, development environment, and partial routing is disabled in the production environment;
2. Disabled routes will not be build

Aug.16,2021

Hello, landlord! Some time ago, I encountered this problem in the development of the project.
first sample source code

tell me my solution.
is distinguished by different commands, such as npm run dev (Development), npm run build (production. The contents of the route.config.js route file introduced by are dynamically generated based on these two commands. It is the contents of the file under the src/modules/router/dynamic path (here you can correspond to two files, one for all routes and one for production). You can take a closer look. If there is anything you don't understand, you can chat in private.

if it is helpful, please click to adopt it. Thank you.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b39b59-2b931.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b39b59-2b931.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?