Return the last portion of a URL, or the host name if there is no path. Trailing /s are ignored, and optional suffix is removed.
URL
/
Please provide a reason for reporting this package. We will review your report and take appropriate action.
Please review the JSR usage policy before submitting a report.
Add Package
deno add jsr:@std/url
Import symbol
import * as mod from "@std/url/basename";
Import directly with a jsr specifier
import * as mod from "jsr:@std/url/basename";