Current way to install -g a tool with deno add?
Hi all,
Not sure if I missed this somewhere in the docs, but perhaps someone else has the same problem, so I’ll ask: suppose I have a script that uses something from @std, let’s say, {resolve} from @std/path.
If I want to install a script
runs without complaint, and the script ends up in the path as expected, but when I try to use it I get the error:
But as mentioned above, I already had done
Any suggestions? TIA.
Not sure if I missed this somewhere in the docs, but perhaps someone else has the same problem, so I’ll ask: suppose I have a script that uses something from @std, let’s say, {resolve} from @std/path.
If I want to install a script
do-thing.js and it contains import {resolve} from "@std/path" (this is after running $ deno add jsr:@std/path), do I have to do anything to install that as a utility?runs without complaint, and the script ends up in the path as expected, but when I try to use it I get the error:
error: Relative import path "@std/fs" not prefixed with / or ./ or ../
hint: If you want to use a JSR or npm package, try running deno add jsr:@std/fs or deno add npm:@std/fs
at file:///Users/me/do-thing.js:3:26
But as mentioned above, I already had done
deno add @std/path.Any suggestions? TIA.
