Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/molt/lib/dependency.ts>parse

Update dependencies the Deno way
Latest
function parse
import { parse } from "https://deno.land/x/molt@0.17.2/lib/dependency.ts";

Parse properties of a dependency from the given URL.

Examples

Example 1

const { name, version, path } = Dependency.parse(
  new URL("https://deno.land/std@0.200.0/fs/mod.ts")
);
// -> { name: "deno.land/std", version: "0.200.0", path: "/fs/mod.ts" }

Parameters

url: string | URL