UNPKG

recoder-code

Version:

🚀 AI-powered development platform - Chat with 32+ models, build projects, automate workflows. Free models included!

11 lines (10 loc) • 282 B
import { parseUrl } from "@smithy/url-parser"; export const toEndpointV1 = (endpoint) => { if (typeof endpoint === "object") { if ("url" in endpoint) { return parseUrl(endpoint.url); } return endpoint; } return parseUrl(endpoint); };