Running below code brings me path without project folder
const path = require('path')
const absolutepath = path.resolve(argv.directory)
D:\\packages\\example\\dist
However real absolute path is
D:\project\packages\example\dist
Can someone help me , why I cant get project folder in absolute path
Simply with :
__dirname
Example :
console.log( __dirname )
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.