File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ function readManifest () {
1313 return manifest
1414 }
1515 try {
16- const manifestPath = path . resolve ( __dirname , '../public/build/manifest.json' )
16+ const manifestPath = path . resolve ( __dirname , '../public/build/.vite/ manifest.json' )
1717 if ( fs . existsSync ( manifestPath ) ) {
1818 manifest = JSON . parse ( fs . readFileSync ( manifestPath , 'utf-8' ) )
1919 return manifest
@@ -81,15 +81,16 @@ function getViteAssets (entryName) {
8181function generateTags ( assets ) {
8282 let cssTags = ''
8383 let jsTags = ''
84- const isProduction = process . env . NODE_ENV === 'production'
84+ // const isProduction = process.env.NODE_ENV === 'production'
8585
8686 assets . css . forEach ( href => {
8787 cssTags += `<link rel="stylesheet" href="${ href } ">\n`
8888 } )
8989
9090 assets . js . forEach ( src => {
9191 // All scripts in dev mode should be modules
92- const typeAttr = ! isProduction ? ' type="module"' : ''
92+ // const typeAttr = !isProduction ? ' type="module"' : ''
93+ const typeAttr = ' type="module"'
9394 jsTags += `<script src="${ src } "${ typeAttr } ></script>\n`
9495 } )
9596
You can’t perform that action at this time.
0 commit comments