File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -236,7 +236,9 @@ export class Vite {
236
236
for ( const entryPoint of jsEntrypoints ) {
237
237
const filePath = join ( server . config . root , entryPoint )
238
238
const entryMod = server . moduleGraph . getModuleById ( string . toUnixSlash ( filePath ) )
239
- if ( entryMod ) this . #collectCss( entryMod , preloadUrls , visitedModules )
239
+ if ( entryMod ) {
240
+ this . #collectCss( entryMod , preloadUrls , visitedModules )
241
+ }
240
242
}
241
243
242
244
/**
@@ -246,7 +248,7 @@ export class Vite {
246
248
const elements = Array . from ( preloadUrls ) . map ( ( href ) =>
247
249
this . #generateElement( {
248
250
tag : 'link' ,
249
- attributes : { rel : 'stylesheet' , as : 'style' , href : href } ,
251
+ attributes : { rel : 'stylesheet' , href : href } ,
250
252
} )
251
253
)
252
254
elements . forEach ( ( element ) => cssTagsElement . add ( element ) )
You can’t perform that action at this time.
0 commit comments