1// Source Code: lib/path.js
2// Description: The path module provides utilities for working with file and
3// directory paths. It can be accessed using:
4
5const path = require('path')
6path.dirname('/foo/asdf/quux')
7// Returns: '/foo/asdf'
8/* dirname(Value <string>) Returns: <string>
9 The path.dirname() method returns the directory name of a path,
10 similar to the Unix dirname command. Trailing directory separators
11 are ignored, see path.sep. A TypeError is thrown if path is not a string. */
1/* The path.dirname() method returns the directory name of a path,
2similar to the Unix dirname command. Trailing directory separators
3are ignored, see path.sep. */
4
5path.dirname('/foo/bar/baz/asdf/quux');
6// Returns: '/foo/bar/baz/asdf'