DefinitelyTyped/types/parse-filepath/parse-filepath-tests.ts
2018-12-25 14:23:55 +01:00

17 lines
589 B
TypeScript

import parsePath = require('parse-filepath');
const parsedPath = parsePath('foo/bar/baz/index.js');
parsedPath.absolute; // $ExpectType string
parsedPath.base; // $ExpectType string
parsedPath.basename; // $ExpectType string
parsedPath.dir; // $ExpectType string
parsedPath.dirname; // $ExpectType string
parsedPath.ext; // $ExpectType string
parsedPath.extname; // $ExpectType string
parsedPath.isAbsolute; // $ExpectType boolean
parsedPath.name; // $ExpectType string
parsedPath.path; // $ExpectType string
parsedPath.root; // $ExpectType string
parsedPath.stem; // $ExpectType string