(path: string)
| 7 | } |
| 8 | |
| 9 | export function parse(path: string) { |
| 10 | const base = basename(path) |
| 11 | const dir = dirname(path) |
| 12 | const [name, ext] = base.split('.') |
| 13 | return { root: '/', dir, base, ext, name } |
| 14 | } |
| 15 | |
| 16 | export function basename(path: string) { |
| 17 | const parts = path.split('/') |
no test coverage detected
searching dependent graphs…