Determine portfolio base URL from the repository structure.
Check the presence of ./dist/index.html
to return either ./dist/
either ./
as base path.
Usage
import { getBaseUrl } from "url_utils.ts";
Determine portfolio base URL from the repository structure.
Check the presence of ./dist/index.html
to return either ./dist/
either ./
as base path.
import { getBaseUrl } from "url_utils.ts";