Primeiro commit do projeto Angular
This commit is contained in:
+11
@@ -0,0 +1,11 @@
|
||||
# This file is used by the build system to adjust CSS and JS output to support the specified browsers below.
|
||||
# For additional information regarding the format and rule options, please see:
|
||||
# https://github.com/browserslist/browserslist#queries
|
||||
|
||||
# For Angular's browser support policy, please see:
|
||||
# https://angular.dev/reference/versions#browser-support
|
||||
|
||||
# You can see what browsers were selected by your queries by running:
|
||||
# npx browserslist
|
||||
|
||||
baseline widely available on <%= baselineDate %>
|
||||
+38
@@ -0,0 +1,38 @@
|
||||
// Karma configuration file, see link for more information
|
||||
// https://karma-runner.github.io/1.0/config/configuration-file.html
|
||||
|
||||
module.exports = function (config) {
|
||||
config.set({
|
||||
basePath: '',
|
||||
frameworks: ['jasmine'<% if (needDevkitPlugin) { %>, '@angular-devkit/build-angular'<% } %>],
|
||||
plugins: [
|
||||
require('karma-jasmine'),
|
||||
require('karma-chrome-launcher'),
|
||||
require('karma-jasmine-html-reporter'),
|
||||
require('karma-coverage'),<% if (needDevkitPlugin) { %>
|
||||
require('@angular-devkit/build-angular/plugins/karma')<% } %>
|
||||
],
|
||||
client: {
|
||||
jasmine: {
|
||||
// you can add configuration options for Jasmine here
|
||||
// the possible options are listed at https://jasmine.github.io/api/edge/Configuration.html
|
||||
// for example, you can disable the random execution with `random: false`
|
||||
// or set a specific seed with `seed: 4321`
|
||||
},
|
||||
},
|
||||
jasmineHtmlReporter: {
|
||||
suppressAll: true // removes the duplicated traces
|
||||
},
|
||||
coverageReporter: {
|
||||
dir: require('path').join(__dirname, '<%= relativePathToWorkspaceRoot %>/coverage/<%= folderName %>'),
|
||||
subdir: '.',
|
||||
reporters: [
|
||||
{ type: 'html' },
|
||||
{ type: 'text-summary' }
|
||||
]
|
||||
},
|
||||
reporters: ['progress', 'kjhtml'],
|
||||
browsers: ['Chrome'],
|
||||
restartOnFileChange: true
|
||||
});
|
||||
};
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
// Learn more about Vitest configuration options at https://vitest.dev/config/
|
||||
|
||||
import { defineConfig } from 'vitest/config';
|
||||
|
||||
export default defineConfig({
|
||||
test: {
|
||||
// ...
|
||||
},
|
||||
});
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @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.dev/license
|
||||
*/
|
||||
import { RuleFactory } from '@angular-devkit/schematics';
|
||||
import { Schema as ConfigOptions } from './schema';
|
||||
declare const configSchematic: RuleFactory<ConfigOptions>;
|
||||
export default configSchematic;
|
||||
+143
@@ -0,0 +1,143 @@
|
||||
"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.dev/license
|
||||
*/
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
const schematics_1 = require("@angular-devkit/schematics");
|
||||
const node_path_1 = require("node:path");
|
||||
const paths_1 = require("../utility/paths");
|
||||
const project_1 = require("../utility/project");
|
||||
const workspace_1 = require("../utility/workspace");
|
||||
const workspace_models_1 = require("../utility/workspace-models");
|
||||
const schema_1 = require("./schema");
|
||||
const configSchematic = (0, project_1.createProjectSchematic)((options, { project }) => {
|
||||
switch (options.type) {
|
||||
case schema_1.Type.Karma:
|
||||
return addKarmaConfig(options);
|
||||
case schema_1.Type.Browserslist:
|
||||
return addBrowserslistConfig(project.root);
|
||||
case schema_1.Type.Vitest:
|
||||
return addVitestConfig(options);
|
||||
default:
|
||||
throw new schematics_1.SchematicsException(`"${options.type}" is an unknown configuration file type.`);
|
||||
}
|
||||
});
|
||||
exports.default = configSchematic;
|
||||
function addVitestConfig(options) {
|
||||
return (tree, context) => (0, workspace_1.updateWorkspace)((workspace) => {
|
||||
const project = workspace.projects.get(options.project);
|
||||
if (!project) {
|
||||
throw new schematics_1.SchematicsException(`Project name "${options.project}" doesn't not exist.`);
|
||||
}
|
||||
const testTarget = project.targets.get('test');
|
||||
if (!testTarget) {
|
||||
throw new schematics_1.SchematicsException(`No "test" target found for project "${options.project}".` +
|
||||
' A "test" target is required to generate a Vitest configuration.');
|
||||
}
|
||||
if (testTarget.builder !== workspace_models_1.Builders.BuildUnitTest) {
|
||||
throw new schematics_1.SchematicsException(`Cannot add a Vitest configuration as builder for "test" target in project does not` +
|
||||
` use "${workspace_models_1.Builders.BuildUnitTest}".`);
|
||||
}
|
||||
testTarget.options ??= {};
|
||||
testTarget.options.runnerConfig = true;
|
||||
// Check runner option.
|
||||
if (testTarget.options.runner === 'karma') {
|
||||
context.logger.warn(`The "test" target is configured to use the "karma" runner in the main options.` +
|
||||
' The generated "vitest-base.config.ts" file may not be used.');
|
||||
}
|
||||
for (const [name, config] of Object.entries(testTarget.configurations ?? {})) {
|
||||
if (config &&
|
||||
typeof config === 'object' &&
|
||||
'runner' in config &&
|
||||
config.runner === 'karma') {
|
||||
context.logger.warn(`The "test" target's "${name}" configuration is configured to use the "karma" runner.` +
|
||||
' The generated "vitest-base.config.ts" file may not be used for that configuration.');
|
||||
}
|
||||
}
|
||||
return (0, schematics_1.mergeWith)((0, schematics_1.apply)((0, schematics_1.url)('./files'), [
|
||||
(0, schematics_1.filter)((p) => p.endsWith('vitest-base.config.ts.template')),
|
||||
(0, schematics_1.applyTemplates)({}),
|
||||
(0, schematics_1.move)(project.root),
|
||||
]));
|
||||
});
|
||||
}
|
||||
async function addBrowserslistConfig(projectRoot) {
|
||||
return (0, schematics_1.mergeWith)((0, schematics_1.apply)((0, schematics_1.url)('./files'), [
|
||||
(0, schematics_1.filter)((p) => p.endsWith('.browserslistrc.template')),
|
||||
// The below is replaced by bazel `npm_package`.
|
||||
(0, schematics_1.applyTemplates)({ baselineDate: '2025-10-20' }),
|
||||
(0, schematics_1.move)(projectRoot),
|
||||
]));
|
||||
}
|
||||
function addKarmaConfig(options) {
|
||||
return (_, context) => (0, workspace_1.updateWorkspace)((workspace) => {
|
||||
const project = workspace.projects.get(options.project);
|
||||
if (!project) {
|
||||
throw new schematics_1.SchematicsException(`Project name "${options.project}" doesn't not exist.`);
|
||||
}
|
||||
const testTarget = project.targets.get('test');
|
||||
if (!testTarget) {
|
||||
throw new schematics_1.SchematicsException(`No "test" target found for project "${options.project}".` +
|
||||
' A "test" target is required to generate a karma configuration.');
|
||||
}
|
||||
if (testTarget.builder !== workspace_models_1.Builders.Karma &&
|
||||
testTarget.builder !== workspace_models_1.Builders.BuildKarma &&
|
||||
testTarget.builder !== workspace_models_1.Builders.BuildUnitTest) {
|
||||
throw new schematics_1.SchematicsException(`Cannot add a karma configuration as builder for "test" target in project does not` +
|
||||
` use "${workspace_models_1.Builders.Karma}", "${workspace_models_1.Builders.BuildKarma}", or ${workspace_models_1.Builders.BuildUnitTest}.`);
|
||||
}
|
||||
testTarget.options ??= {};
|
||||
if (testTarget.builder !== workspace_models_1.Builders.BuildUnitTest) {
|
||||
testTarget.options.karmaConfig = node_path_1.posix.join(project.root, 'karma.conf.js');
|
||||
}
|
||||
else {
|
||||
// `unit-test` uses the `runnerConfig` option which has configuration discovery if enabled
|
||||
testTarget.options.runnerConfig = true;
|
||||
let isKarmaRunnerConfigured = false;
|
||||
// Check runner option
|
||||
if (testTarget.options.runner) {
|
||||
if (testTarget.options.runner === 'karma') {
|
||||
isKarmaRunnerConfigured = true;
|
||||
}
|
||||
else {
|
||||
context.logger.warn(`The "test" target is configured to use a runner other than "karma" in the main options.` +
|
||||
' The generated "karma.conf.js" file may not be used.');
|
||||
}
|
||||
}
|
||||
for (const [name, config] of Object.entries(testTarget.configurations ?? {})) {
|
||||
if (config && typeof config === 'object' && 'runner' in config) {
|
||||
if (config.runner !== 'karma') {
|
||||
context.logger.warn(`The "test" target's "${name}" configuration is configured to use a runner other than "karma".` +
|
||||
' The generated "karma.conf.js" file may not be used for that configuration.');
|
||||
}
|
||||
else {
|
||||
isKarmaRunnerConfigured = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!isKarmaRunnerConfigured) {
|
||||
context.logger.warn(`The "test" target is not explicitly configured to use the "karma" runner.` +
|
||||
' The generated "karma.conf.js" file may not be used as the default runner is "vitest".');
|
||||
}
|
||||
}
|
||||
// If scoped project (i.e. "@foo/bar"), convert dir to "foo/bar".
|
||||
let folderName = options.project.startsWith('@') ? options.project.slice(1) : options.project;
|
||||
if (/[A-Z]/.test(folderName)) {
|
||||
folderName = schematics_1.strings.dasherize(folderName);
|
||||
}
|
||||
return (0, schematics_1.mergeWith)((0, schematics_1.apply)((0, schematics_1.url)('./files'), [
|
||||
(0, schematics_1.filter)((p) => p.endsWith('karma.conf.js.template')),
|
||||
(0, schematics_1.applyTemplates)({
|
||||
relativePathToWorkspaceRoot: (0, paths_1.relativePathToWorkspaceRoot)(project.root),
|
||||
folderName,
|
||||
needDevkitPlugin: testTarget.builder === workspace_models_1.Builders.Karma,
|
||||
}),
|
||||
(0, schematics_1.move)(project.root),
|
||||
]));
|
||||
});
|
||||
}
|
||||
//# sourceMappingURL=index.js.map
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;AAEH,2DAWoC;AACpC,yCAA0C;AAC1C,4CAA+D;AAC/D,gDAA4D;AAC5D,oDAAuD;AACvD,kEAAyE;AACzE,qCAAuE;AAEvE,MAAM,eAAe,GAA+B,IAAA,gCAAsB,EACxE,CAAC,OAAO,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE;IACvB,QAAQ,OAAO,CAAC,IAAI,EAAE,CAAC;QACrB,KAAK,aAAU,CAAC,KAAK;YACnB,OAAO,cAAc,CAAC,OAAO,CAAC,CAAC;QACjC,KAAK,aAAU,CAAC,YAAY;YAC1B,OAAO,qBAAqB,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;QAC7C,KAAK,aAAU,CAAC,MAAM;YACpB,OAAO,eAAe,CAAC,OAAO,CAAC,CAAC;Q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2B,EAAE,IAAA,mCAA2B,EAAC,OAAO,CAAC,IAAI,CAAC;gBACtE,UAAU;gBACV,gBAAgB,EAAE,UAAU,CAAC,OAAO,KAAK,2BAAc,CAAC,KAAK;aAC9D,CAAC;YACF,IAAA,iBAAI,EAAC,OAAO,CAAC,IAAI,CAAC;SACnB,CAAC,CACH,CAAC;IACJ,CAAC,CAAC,CAAC;AACP,CAAC"}
|
||||
+23
@@ -0,0 +1,23 @@
|
||||
/**
|
||||
* Generates configuration files for your project. These files control various aspects of
|
||||
* your project's build process, testing, and browser compatibility. This schematic helps
|
||||
* you create or update essential configuration files with ease.
|
||||
*/
|
||||
export type Schema = {
|
||||
/**
|
||||
* The name of the project where the configuration file should be created or updated.
|
||||
*/
|
||||
project: string;
|
||||
/**
|
||||
* Specifies the type of configuration file to generate.
|
||||
*/
|
||||
type: Type;
|
||||
};
|
||||
/**
|
||||
* Specifies the type of configuration file to generate.
|
||||
*/
|
||||
export declare enum Type {
|
||||
Browserslist = "browserslist",
|
||||
Karma = "karma",
|
||||
Vitest = "vitest"
|
||||
}
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
"use strict";
|
||||
// THIS FILE IS AUTOMATICALLY GENERATED. TO UPDATE THIS FILE YOU NEED TO CHANGE THE
|
||||
// CORRESPONDING JSON SCHEMA FILE, THEN RUN devkit-admin build (or bazel build ...).
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.Type = void 0;
|
||||
/**
|
||||
* Specifies the type of configuration file to generate.
|
||||
*/
|
||||
var Type;
|
||||
(function (Type) {
|
||||
Type["Browserslist"] = "browserslist";
|
||||
Type["Karma"] = "karma";
|
||||
Type["Vitest"] = "vitest";
|
||||
})(Type || (exports.Type = Type = {}));
|
||||
//# sourceMappingURL=schema.js.map
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"schema.js","sourceRoot":"","sources":["schema.ts"],"names":[],"mappings":";AACA,mFAAmF;AACnF,oFAAoF;;;AAkBpF;;GAEG;AACH,IAAY,IAIX;AAJD,WAAY,IAAI;IACZ,qCAA6B,CAAA;IAC7B,uBAAe,CAAA;IACf,yBAAiB,CAAA;AACrB,CAAC,EAJW,IAAI,oBAAJ,IAAI,QAIf"}
|
||||
+28
@@ -0,0 +1,28 @@
|
||||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema",
|
||||
"$id": "SchematicsAngularConfig",
|
||||
"title": "Angular Config File Options Schema",
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"description": "Generates configuration files for your project. These files control various aspects of your project's build process, testing, and browser compatibility. This schematic helps you create or update essential configuration files with ease.",
|
||||
"properties": {
|
||||
"project": {
|
||||
"type": "string",
|
||||
"description": "The name of the project where the configuration file should be created or updated.",
|
||||
"$default": {
|
||||
"$source": "projectName"
|
||||
}
|
||||
},
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "Specifies the type of configuration file to generate.",
|
||||
"enum": ["karma", "browserslist", "vitest"],
|
||||
"x-prompt": "Which type of configuration file would you like to create?",
|
||||
"$default": {
|
||||
"$source": "argv",
|
||||
"index": 0
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["project", "type"]
|
||||
}
|
||||
Reference in New Issue
Block a user