jsr-io / jsr

The open-source package registry for modern JavaScript and TypeScript
https://jsr.io
MIT License
2.2k stars 99 forks source link

Make packages installable (binary) #297

Open m-dressler opened 4 months ago

m-dressler commented 4 months ago

Not sure if this is better to bring up here or in deno's repo, but I'd like to be able to host an installable (not 'addable') package on jsr.io, i.e., deno install @example/my-runnable-package.

Maybe this is already possible but not documented which URL I would need to install from, and it's as easy as marking a package as installable which updates the JSR installation instructions:

{
  "version": "1.0.0",
  "installable": true,
  "exports": "./main.ts",
  "imports": {
    "@example/package": "jsr:@example/package@^1.0.0"
  }
}
lucacasonato commented 3 months ago

In Deno you can install a JSR package with deno install jsr:@example/package.

m-dressler commented 3 months ago

@lucacasonato Thank you! Probably just starting to work with Deno here. I personally would feel it would be nice to have jsr: be the default inferred package manager for deno install, but if that's not on the table this issue can be closed :)