ECMAScript defines 2 types of work as required: Promise Jobs and Script Jobs. The situation with Promise Jobs is clear: I created a Promise or an asynchronous function for myself - and everything, the new Promise Job has been created and added to the queue.
But what about Script Jobs? What needs to be done to create a job of this type?
I know that the module code is also related to Script Jobs. But doesn’t the module import its code immediately? Although the specification says that the work is needed in order to be “postponed” and executed later (as in the situation with Promise).
In short, what needs to be done to initiate a new job and add it to the Script Jobs queue?