UNPKG

@types/app-root-path

Version:
57 lines (45 loc) 1.56 kB
# Installation > `npm install --save @types/app-root-path` # Summary This package contains type definitions for app-root-path (https://github.com/inxilpro/node-app-root-path). # Details Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/app-root-path. ## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/app-root-path/index.d.ts) ````ts // Type definitions for app-root-path 1.2.1 // Project: https://github.com/inxilpro/node-app-root-path // Definitions by: Shant Marouti <https://github.com/shantmarouti> // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped interface RootPath { /** * Application root directory absolute path */ path: string; /** * Resolves relative path from root to absolute path * @param {string} pathToModule * @returns {string} */ resolve(pathToModule: string): string; /** * Resolve module by relative addressing from root * @param {string} pathToModule * @returns {*} */ require(pathToModule: string): any; /** * Explicitly set root path * @param {string} explicitlySetPath */ setPath(explicitlySetPath: string): void; toString(): string; } declare const RootPath: RootPath; export = RootPath; ```` ### Additional Details * Last updated: Sat, 29 Apr 2023 04:03:29 GMT * Dependencies: none * Global values: none # Credits These definitions were written by [Shant Marouti](https://github.com/shantmarouti).