It looks like node v12's REPL will run javascript code as you type it into the console. This has some annoying interactions with shelljs commands though because:
these have side effects (ex. shell.clear() clears the console)
n_shell has a feature to execute commands without typing parentheses (ex. ls<CR> is the same as ls()<CR>)
These combine to make for a really unpleasant user experience. Ex. typing touch (without pressing enter) will cause touch() to be eagerly executed by the REPL preview, which outputs an error (touch: no files given).
Maybe we should just disable the feature referenced in (2) and require parentheses. For some reason the node REPL won't show the preview for ls(), only for ls.
It looks like node v12's REPL will run javascript code as you type it into the console. This has some annoying interactions with shelljs commands though because:
shell.clear()
clears the console)n_shell
has a feature to execute commands without typing parentheses (ex.ls<CR>
is the same asls()<CR>
)These combine to make for a really unpleasant user experience. Ex. typing
touch
(without pressing enter) will causetouch()
to be eagerly executed by the REPL preview, which outputs an error (touch: no files given
).Maybe we should just disable the feature referenced in (2) and require parentheses. For some reason the node REPL won't show the preview for
ls()
, only forls
.