JavaScript Library
PATH
nata_developer
2020. 8. 7. 18:27
1.path.resolve()
path.resolve() 메써드는 일련의 경로들 혹은 경로 조각들을 절대 경로로 합친다.
path: path.resolve(__dirname, 'dist')
참고-https://nodejs.org/api/path.html
Path | Node.js v14.7.0 Documentation
Path# Source Code: lib/path.js The path module provides utilities for working with file and directory paths. It can be accessed using: const path = require('path'); Windows vs. POSIX# The default operation of the path module varies based on the operating s
nodejs.org
*__dirname
최근 모듈의 directory이름이다. __dirname은 __filename의 path.diranme()과 같다.