no-import-prefix
NOTE: this rule is part of the
workspace rule set.Enable full set in
deno.json:{
"lint": {
"rules": {
"tags": ["workspace"]
}
}
}Enable full set using the Deno CLI:
deno lint --rules-tags=workspace
This rule can be explictly included to or excluded from the rules present in the current tag by adding it to the
include or exclude array in deno.json:{
"lint": {
"rules": {
"include": ["no-import-prefix"],
"exclude": ["no-import-prefix"]
}
}
}Ensure that all dependencies are declared in either deno.json or
package.json.
Invalid: Jump to heading
import foo from "https://deno.land/std/path/mod.ts";
import foo from "jsr:@std/path@1";
import foo from "npm:preact@10";
Valid: Jump to heading
// Mapped in `deno.json` or `package.json`
import foo from "@std/path";