UNPKG

@sentry/wizard

Version:

Sentry wizard helping you to configure your project

42 lines 1.74 kB
"use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); exports.configureAngularSourcemapGenerationFlow = exports.angularJsonTemplate = void 0; // @ts-expect-error - clack is ESM and TS complains about that. It works though const prompts_1 = __importDefault(require("@clack/prompts")); const chalk_1 = __importDefault(require("chalk")); const clack_1 = require("../../utils/clack"); exports.angularJsonTemplate = (0, clack_1.makeCodeSnippet)(true, (unchanged, plus) => unchanged(`{ "projects": { 'your-project': { "architect": { "build": { "options": { ${plus(`"sourceMap": true`)} }, }, } } } }`)); async function configureAngularSourcemapGenerationFlow() { prompts_1.default.log.info(`Enable generating source maps in your ${chalk_1.default.bold('angular.json')} file:`); // Intentionally logging directly to console here so that the code can be copied/pasted directly // eslint-disable-next-line no-console console.log(exports.angularJsonTemplate); await (0, clack_1.abortIfCancelled)(prompts_1.default.select({ message: `Verify that you are generating source maps when building your Angular app.`, options: [ { label: 'I checked!', hint: 'My build output folder contains .js.map files after a build.', value: true, }, ], initialValue: true, })); } exports.configureAngularSourcemapGenerationFlow = configureAngularSourcemapGenerationFlow; //# sourceMappingURL=angular.js.map