I am developing a custom Angular Schematic. This schematic has to access a folder inside the Angular project that will make use of the schematic. (The folder contains config files needed to generate my .ts files). The schematic will prompt the user for the path (stored in configFilesPath)
So far, I can only access this folder this way:
export const readConfigFilefromPath = (configFilesPath: string): string | undefined => {
// ...
const path = __dirname + "\\..\\..\\..\\..\\..\\src\\app\\" + configFilesPath;
// ...
}
Is there a better way to access the path from the schematic?