Expand description
Dotenv files as Nx reads them, with npm’s dotenv and dotenv-expand:
every file of a set is parsed first, then $VAR and ${VAR} references
are expanded once across all of them.
Functions§
- load
- Reads
pathsintoenvas Nx’sloadAndExpandDotEnvFiledoes. The files are merged first, the first to set a key winning; each keyenvdoes not hold is set; then each value is expanded againstenvand what the files expanded before it, and set, which also fills a variable set but empty. A variableenvalready holds with another value keeps it. A file that does not exist is skipped. - parse
- The entries of one dotenv file, in order, as
dotenv’sparsereads them: lines it cannot read are left out, a key given twice keeps its first place and its last value, quotes are removed, and\nand\rbecome line breaks inside double quotes. Nothing is expanded here. - read_
alone - The variables of one file as
loadwould set them in an empty environment: what Nx compares to unload a root dotenv file.