Skip to main content

from

The from keyword names the source module in a selective import, specifying which module the listed symbols come from.


Syntax & Example

import { HashMap } from "adesh_alloc";
import { open, readAll } from "fs";

Use Cases

  • Importing specific named symbols from a module.
  • Combining with import and as for fine-grained, renamed imports.

See also: import, as.