Requirejs loading css, page will stutter and then load the style, how to solve it?

page js and css are introduced through requirejs, due to the order, there is no css appearance first, and then load the style, the page is normal, is there any way to solve this problem?

Feb.24,2022

js resource loading takes a certain time, and flickering is inevitable. In this case, you can consider making some loading optimization
for example: loading starts loading, some css layout-related files or js files are loaded (processed in the callback after loading is successful), and loading
is finished. Otherwise, you can only split the style or introduce it in the way of header link or @ import. Possible changes are relatively large


css extracted and put in front of loading


you can put css in front of the dependency, or you can configure the css path in the deps array of modules in require.config

require(["css!../style.css", "module"], function(){

})

//
require.config({
    shim:{
        module:["css!../style.css"]
    }
})

require(["module"], function(){})
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-1bf20d4-31dd7.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-1bf20d4-31dd7.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?