Buckets:
| import { parsePath } from './parse-path' | |
| /** | |
| * Similarly to `addPathPrefix`, this function adds a suffix at the end on the | |
| * provided path. It also works only for paths ensuring the argument starts | |
| * with a slash. | |
| */ | |
| export function addPathSuffix(path: string, suffix?: string) { | |
| if (!path.startsWith('/') || !suffix) { | |
| return path | |
| } | |
| const { pathname, query, hash } = parsePath(path) | |
| return `${pathname}${suffix}${query}${hash}` | |
| } | |
Xet Storage Details
- Size:
- 449 Bytes
- Xet hash:
- a82fc33430347a4da3a836771eb4faea0bc06a201f046c51614442ecceb69434
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.