From ee758dd891aed75e4138911a4faa5b12bc2b2941 Mon Sep 17 00:00:00 2001 From: Leo Kettmeir Date: Tue, 27 May 2025 21:26:02 +0200 Subject: [PATCH] feat: add vlt to usage dropdown --- api/src/docs.rs | 10 ++++++++++ frontend/docs/npm-compatibility.md | 17 +++++++++++------ frontend/static/logos/vlt.svg | 11 +++++++++++ 3 files changed, 32 insertions(+), 6 deletions(-) create mode 100644 frontend/static/logos/vlt.svg diff --git a/api/src/docs.rs b/api/src/docs.rs index ed7e04ad..27a07c22 100644 --- a/api/src/docs.rs +++ b/api/src/docs.rs @@ -1246,6 +1246,16 @@ impl deno_doc::html::UsageComposer for DocUsageComposer { }, format!("Add Package\n```\nyarn add jsr:{scoped_name}\n```\n
or (using Yarn 4.8 or older)
\n\n```\nyarn dlx jsr add {scoped_name}\n```{import}"), ); + map.insert( + UsageComposerEntry { + name: "vlt".to_string(), + icon: Some( + r#"vlt logo"# + .into(), + ), + }, + format!("Add Package\n```\nvlt install jsr:{scoped_name}\n```{import}"), + ); map.insert( UsageComposerEntry { name: "npm".to_string(), diff --git a/frontend/docs/npm-compatibility.md b/frontend/docs/npm-compatibility.md index 3a3fc880..b7a3270a 100644 --- a/frontend/docs/npm-compatibility.md +++ b/frontend/docs/npm-compatibility.md @@ -19,9 +19,10 @@ downloaded from jsr.io and installed in your `node_modules` directory. ## Installing and using JSR packages -If you are using a recent version of pnpm (10.9+) or Yarn (4.9+), you can -install JSR packages using `pnpm install` or `yarn add` without any additional -configuration. These versions of pnpm and Yarn both support JSR out of the box. +If you are using a recent version of pnpm (10.9+), Yarn (4.9+) or vlt, you can +install JSR packages using `pnpm install`, `yarn add` or `vlt install` without +any additional configuration. These versions of pnpm and Yarn both support JSR +out of the box. ```sh pnpm install jsr:@luca/cases @@ -31,6 +32,10 @@ pnpm install jsr:@luca/cases yarn add jsr:@luca/cases ``` +```sh +vlt install jsr:@luca/cases +``` + If you are using npm, an older version of pnpm or Yarn, or Bun, you can use the JSR CLI to install JSR packages: @@ -88,9 +93,9 @@ from npm. The `@jsr` npm scope is served from the JSR registry at `https://npm.jsr.io`. -Recent versions of `yarn` and `pnpm` automatically configure pull packages in -the `@jsr` scope from `https://npm.jsr.io`, so you don't need to do anything -special to use JSR packages with these package managers. +Recent versions of `yarn`, `pnpm` and `vlt` automatically configure pull +packages in the `@jsr` scope from `https://npm.jsr.io`, so you don't need to do +anything special to use JSR packages with these package managers. For other package managers, and older versions of `yarn` and `pnpm`, you need to configure your package manager to use the JSR registry to install JSR packages. diff --git a/frontend/static/logos/vlt.svg b/frontend/static/logos/vlt.svg new file mode 100644 index 00000000..9e637493 --- /dev/null +++ b/frontend/static/logos/vlt.svg @@ -0,0 +1,11 @@ + + + + + + + + + + +