js中__dirname、__fillname

__dirname Get the absolute path of the current file's directory
__fillname Get the absolute path of the current file

For example:

API path
__dirname D:\Node learning
__fillname D:\Node Learning\index.html

Built-in, used directly, no need to import

Guess you like

Origin blog.csdn.net/qq_52421092/article/details/130106526