我有一个脚本foo.js,其中包含我想在REPL中使用的一些函数.
foo.js
有没有办法让节点执行我的脚本,然后跳转到一个包含所有声明的全局变量的REPL,就像我可以使用python -i foo.py或ghci foo.hs?
python -i foo.py
ghci foo.hs
javascript node.js read-eval-print-loop
javascript ×1
node.js ×1
read-eval-print-loop ×1