【问题标题】:Is there a code for saving your codes on Node.js是否有将代码保存在 Node.js 上的代码
【发布时间】:2022-02-23 06:02:59
【问题描述】:
let dairy = [];

function records(events,experience) { dairy.push({events,experience});
};

如何保存我的函数,这样我就不必在关机后编写代码?

【问题讨论】:

    标签: javascript node.js function


    【解决方案1】:

    请参阅the getting started guide,它指导您在带有.js 文件扩展名的文本文件中编写代码,然后使用node yourfilename.js 运行它,而不仅仅是在 REPL 中键入所有内容。

    【讨论】:

      猜你喜欢
      • 2017-11-10
      • 1970-01-01
      • 2020-12-27
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-11-17
      • 1970-01-01
      相关资源
      最近更新 更多