Why is the nodejs CommonJS Synchronize and the front-end amd,cmd asynchronous? What about the es6 module?

Why is the nodejs CommonJS Synchronize and the front-end amd,cmd asynchronous? What about the es6 module?

Mar.20,2021

for the backend, Synchronize loading is not a problem, because

  1. modules are all local, and the waiting time is the hard disk time;
  2. once started, it usually does not turn off, and reliability is more important than startup time.

for the front end

  1. modules are all on the server and need to be requested through the network, which is too slow;
  2. Synchronize xhr will block browsers. If you fake death, the user experience is poor, and the time of the first screen is very important.

when designing the es6 module, you didn't force Synchronize or async. But all browsers add defer by default to < script type= "module" > < / script > , so it can also be considered asynchronous.

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-1ea4d6f-1d0d.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-1ea4d6f-1d0d.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?