The {“extends”: “solhint:recommended”} property in a configuration file enables this rule.
Import statement includes an entire file instead of selected symbols.
This rule accepts a string option of rule severity. Must be one of “error”, “warn”, “off”. Default to warn.
{
"rules": {
"no-global-import": "warn"
}
}
import {A} from "./A.sol"
import "./A.sol" as A
import * as A from "./A.sol"
import * from "foo.sol"
import "foo.sol"
This rule was introduced in Solhint 3.4.0