We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 125ed0c commit 330c1bcCopy full SHA for 330c1bc
doc/api/worker_threads.md
@@ -1255,7 +1255,9 @@ import {
1255
1256
if (isMainThread) {
1257
new Worker(new URL(import.meta.url));
1258
- for (let n = 0; n < 1e10; n++) {}
+ for (let n = 0; n < 1e10; n++) {
1259
+ // Looping to simulate work.
1260
+ }
1261
} else {
1262
// This output will be blocked by the for loop in the main thread.
1263
console.log('foo');
@@ -1272,7 +1274,9 @@ const {
1272
1274
1273
1275
1276
new Worker(__filename);
1277
1278
1279
1280
1281
1282
0 commit comments