node-cooper - v0.2.0
    Preparing search index...

    Function projectRoot

    • Where .env files are read from unless dotenvDir says otherwise: the directory of the nearest package.json walking up from cwd, else cwd itself. Reading them from the working directory only, as this once did, found none when an application was started from anywhere but its own root (a subdirectory, a test runner, a process manager).

      Parameters

      • Optionalcwd: string = ...

        where to start (default process.cwd())

      Returns string