cmd //進入指令行
D: //指定磁盤
cd 檔案路徑 //指定路徑
node 檔案名.js //執行檔案
增補:
Node執行js檔案自動嵌套
(function(exports,require,module,__filename,__dirname){
js檔案真實内容
輸出通路檔案的絕對路徑(包括檔案名)
console.log(__filename);
cmd //進入指令行
D: //指定磁盤
cd 檔案路徑 //指定路徑
node 檔案名.js //執行檔案
增補:
Node執行js檔案自動嵌套
(function(exports,require,module,__filename,__dirname){
js檔案真實内容
輸出通路檔案的絕對路徑(包括檔案名)
console.log(__filename);