UNPKG

angular-calendar

Version:

A calendar component for angular 20.2+ that can display events on a month, week or day view

24 lines (23 loc) 1.01 kB
"use strict"; /** * @license * Copyright Google LLC All Rights Reserved. * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://angular.io/license */ Object.defineProperty(exports, "__esModule", { value: true }); exports.getProjectMainFile = getProjectMainFile; var schematics_1 = require("@angular-devkit/schematics"); var project_targets_1 = require("./project-targets"); /** Looks for the main TypeScript file in the given project and returns its path. */ function getProjectMainFile(project) { var _a; var buildOptions = (0, project_targets_1.getProjectTargetOptions)(project, 'build'); var mainFile = (_a = buildOptions.browser) !== null && _a !== void 0 ? _a : buildOptions.main; if (typeof mainFile !== 'string') { throw new schematics_1.SchematicsException("Could not find the project main file inside of the " + "workspace config (".concat(project.sourceRoot, ")")); } return mainFile; }