lark-utils
Some utilities for Lark
install
$ npm install --save lark-utils
path
absolute
Get an absolute path
utils.path.absolute(path, basepath);
if path
is already an absolute path, return that path
. Or return the absolute path joined from path
and basepath
, while default value of basepath
is the directory of process.mainModule.filename
basename
Get the basename of a path. This will detect extname automaitically
utils.path.basename('/foo/bar.js'); // ===> bar