extra-path
Version:
Useful additions to inbuilt [@std/path] module.<br>
49 lines (32 loc) ⢠1.25 kB
Markdown
Useful additions to inbuilt [@std/path] module.<br>
ā
š¦ [JSR](https://jsr.io/@nodef/extra-path),
š¦ [NPM](https://www.npmjs.com/package/@nodef/extra-path),
š° [Docs](https://jsr.io/@nodef/extra-path/doc).
[@std/path]: https://deno.land/std/path/mod.ts
<br>
```javascript
import * as xpath from "jsr:@nodef/extra-path";
xpath.filename('/home/user/file+name.txt');
// ā 'file+name'
xpath.symbolname('/home/user/file+name.txt');
// ā 'file_name'
xpath.keywordname('/home/user/file+name.txt');
// ā 'file-name'
```
<br>
<br>
## Index
| Property | Description |
| ---- | ---- |
| [filename] | Get file name without extension. |
| [symbolname] | Get symbol name for file. |
| [keywordname] | Get keyword name for file. |
<br>
<br>
[](https://wolfram77.github.io)<br>
[](https://nodef.github.io)

[filename]: https://jsr.io/@nodef/extra-path/doc/~/filename
[symbolname]: https://jsr.io/@nodef/extra-path/doc/~/symbolname
[keywordname]: https://jsr.io/@nodef/extra-path/doc/~/keywordname