File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -120,12 +120,14 @@ node server.js
120120 // Get all the html template files and forEach them
121121 // E.g, path = './src/pages/user/index/app.html'
122122
123- const filename = path.split('./src/pages/')[1].split('/app.html')[0] + '.html'
124- // E.g, the html filename will be 'user/index.html' in the 'dist' folder
125-
126123 const chunk = path.split('./src/pages/')[1].split('/app.html')[0]
127124 // E,g. the chunk will be 'user/login'
128125
126+ const filename = chunk + '.html'
127+ // E.g, the html filename will be 'user/index.html' in the 'dist' folder
128+
129+
130+
129131 const htmlConf = {
130132 filename: filename,
131133 template: path,
Original file line number Diff line number Diff line change @@ -106,8 +106,8 @@ const config = {
106106}
107107
108108glob . sync ( './src/pages/**/*.html' ) . forEach ( path => {
109- const filename = path . split ( './src/pages/' ) [ 1 ] . split ( '/app.html' ) [ 0 ] + '.html'
110109 const chunk = path . split ( './src/pages/' ) [ 1 ] . split ( '/app.html' ) [ 0 ]
110+ const filename = chunk + '.html'
111111 const htmlConf = {
112112 filename : filename ,
113113 template : path ,
You can’t perform that action at this time.
0 commit comments