File tree Expand file tree Collapse file tree 3 files changed +16
-4
lines changed Expand file tree Collapse file tree 3 files changed +16
-4
lines changed Original file line number Diff line number Diff line change
1
+ import { exec } from 'child_process'
2
+
3
+ const timeout = s => new Promise ( resolve => setTimeout ( resolve , s * 1000 ) ) // ms
4
+
5
+ const sleep = async ( s , message ) => {
6
+ console . log ( "Awaiting Promise…" ) // This selected line should run.
7
+ await timeout ( s )
8
+ return console . log ( message )
9
+ }
10
+
11
+ sleep ( 1 , "Done." )
Original file line number Diff line number Diff line change @@ -431,18 +431,18 @@ module.exports =
431
431
432
432
JavaScript :
433
433
" Selection Based" :
434
- command : " node"
434
+ command : " babel- node"
435
435
args : (context ) -> [' -e' , context .getCode ()]
436
436
" File Based" :
437
- command : " node"
437
+ command : " babel- node"
438
438
args : (context ) -> [context .filepath ]
439
439
440
440
' JavaScript with JSX' :
441
441
" Selection Based" :
442
- command : " node"
442
+ command : " babel- node"
443
443
args : (context ) -> [' -e' , context .getCode ()]
444
444
" File Based" :
445
- command : " node"
445
+ command : " babel- node"
446
446
args : (context ) -> [context .filepath ]
447
447
448
448
" JavaScript for Automation (JXA)" :
Original file line number Diff line number Diff line change 340
340
"uuid" : " ^3.0.1"
341
341
},
342
342
"optionalDependencies" : {
343
+ "babel-cli" : " ^6.26.0" ,
343
344
"coffeescript" : " ^2"
344
345
},
345
346
"devDependencies" : {
You can’t perform that action at this time.
0 commit comments