import-tree icon indicating copy to clipboard operation
import-tree copied to clipboard

Document `addScoped`

Open theutz opened this issue 6 months ago • 1 comments

#31 just landed, allowing users to inject variables into the scope of every module in the tree.

Example:

# flake.nix
import-tree.addScope { colors = ["red" "green" "blue"]; } ./modules
# modules/example.nix
{
  brand.colors = colors;
}

In example.nix, colors does not need to be explicitly imported at the top of the file. It's already in scope.

See #30 for how it will enhance onboarding for den.

theutz avatar May 14 '26 08:05 theutz

fixed in #34

vic avatar May 14 '26 18:05 vic