@schematics/angular 20.2.0-rc.1 → 20.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -39,11 +39,13 @@ const AI_TOOLS = {
39
39
  },
40
40
  };
41
41
  function default_1({ tool }) {
42
- if (!tool || tool.includes(schema_1.Tool.None)) {
42
+ if (!tool) {
43
43
  return (0, schematics_1.noop)();
44
44
  }
45
- const files = tool.map((selectedTool) => AI_TOOLS[selectedTool]);
46
- const rules = files.map(({ rulesName, directory, frontmatter }) => (0, schematics_1.mergeWith)((0, schematics_1.apply)((0, schematics_1.url)('./files'), [
45
+ const rules = tool
46
+ .filter((tool) => tool !== schema_1.Tool.None)
47
+ .map((selectedTool) => AI_TOOLS[selectedTool])
48
+ .map(({ rulesName, directory, frontmatter }) => (0, schematics_1.mergeWith)((0, schematics_1.apply)((0, schematics_1.url)('./files'), [
47
49
  (0, schematics_1.applyTemplates)({
48
50
  ...schematics_1.strings,
49
51
  rulesName,
@@ -9,29 +9,46 @@
9
9
  "tool": {
10
10
  "type": "array",
11
11
  "uniqueItems": true,
12
- "default": "none",
13
- "x-prompt": "Which AI tools do you want to configure with Angular best practices? https://angular.dev/ai/develop-with-ai",
12
+ "default": ["none"],
13
+ "x-prompt": {
14
+ "message": "Which AI tools do you want to configure with Angular best practices? https://angular.dev/ai/develop-with-ai",
15
+ "type": "list",
16
+ "items": [
17
+ {
18
+ "value": "none",
19
+ "label": "None"
20
+ },
21
+ {
22
+ "value": "claude",
23
+ "label": "Claude [ https://docs.anthropic.com/en/docs/claude-code/memory ]"
24
+ },
25
+ {
26
+ "value": "cursor",
27
+ "label": "Cursor [ https://docs.cursor.com/en/context/rules ]"
28
+ },
29
+ {
30
+ "value": "gemini",
31
+ "label": "Gemini [ https://ai.google.dev/gemini-api/docs ]"
32
+ },
33
+ {
34
+ "value": "copilot",
35
+ "label": "GitHub Copilot [ https://code.visualstudio.com/docs/copilot/copilot-customization#_custom-instructions ]"
36
+ },
37
+ {
38
+ "value": "jetbrains",
39
+ "label": "JetBrains AI Assistant [ https://www.jetbrains.com/help/junie/customize-guidelines.html ]"
40
+ },
41
+ {
42
+ "value": "windsurf",
43
+ "label": "Windsurf [ https://docs.windsurf.com/windsurf/cascade/memories#rules ]"
44
+ }
45
+ ]
46
+ },
14
47
  "description": "Specifies which AI tools to generate configuration files for. These file are used to improve the outputs of AI tools by following the best practices.",
15
48
  "items": {
16
49
  "type": "string",
17
50
  "enum": ["none", "gemini", "copilot", "claude", "cursor", "jetbrains", "windsurf"]
18
51
  }
19
52
  }
20
- },
21
- "if": {
22
- "properties": {
23
- "tool": {
24
- "contains": {
25
- "const": "none"
26
- }
27
- }
28
- }
29
- },
30
- "then": {
31
- "properties": {
32
- "tool": {
33
- "maxItems": 1
34
- }
35
- }
36
53
  }
37
54
  }
@@ -27,7 +27,7 @@ const karma_config_analyzer_1 = require("./karma-config-analyzer");
27
27
  * @returns The content of the default `karma.conf.js` file.
28
28
  */
29
29
  async function generateDefaultKarmaConfig(relativePathToWorkspaceRoot, projectName, needDevkitPlugin) {
30
- const templatePath = posix_1.default.join(__dirname, '../../config/files/karma.conf.js.template');
30
+ const templatePath = require.resolve('../../config/files/karma.conf.js.template');
31
31
  let template = await (0, promises_1.readFile)(templatePath, 'utf-8');
32
32
  // TODO: Replace this with the actual schematic templating logic.
33
33
  template = template
@@ -1,4 +1,5 @@
1
1
  {
2
+ "encapsulation": false,
2
3
  "schematics": {
3
4
  "replace-provide-server-rendering-import": {
4
5
  "version": "20.0.0",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@schematics/angular",
3
- "version": "20.2.0-rc.1",
3
+ "version": "20.2.1",
4
4
  "description": "Schematics specific to Angular",
5
5
  "homepage": "https://github.com/angular/angular-cli",
6
6
  "keywords": [
@@ -22,15 +22,15 @@
22
22
  },
23
23
  "schematics": "./collection.json",
24
24
  "dependencies": {
25
- "@angular-devkit/core": "20.2.0-rc.1",
26
- "@angular-devkit/schematics": "20.2.0-rc.1",
25
+ "@angular-devkit/core": "20.2.1",
26
+ "@angular-devkit/schematics": "20.2.1",
27
27
  "jsonc-parser": "3.3.1"
28
28
  },
29
29
  "repository": {
30
30
  "type": "git",
31
31
  "url": "https://github.com/angular/angular-cli.git"
32
32
  },
33
- "packageManager": "pnpm@10.14.0",
33
+ "packageManager": "pnpm@10.15.0",
34
34
  "engines": {
35
35
  "node": "^20.19.0 || ^22.12.0 || >=24.0.0",
36
36
  "npm": "^6.11.0 || ^7.5.6 || >=8.0.0",
@@ -14,9 +14,9 @@ const dependencies = require('./latest-versions/package.json')['dependencies'];
14
14
  exports.latestVersions = {
15
15
  ...dependencies,
16
16
  // As Angular CLI works with same minor versions of Angular Framework, a tilde match for the current
17
- Angular: '^20.2.0-next.0',
18
- NgPackagr: '^20.2.0-next.0',
19
- DevkitBuildAngular: '^20.2.0-rc.1',
20
- AngularBuild: '^20.2.0-rc.1',
21
- AngularSSR: '^20.2.0-rc.1',
17
+ Angular: '^20.2.0',
18
+ NgPackagr: '^20.2.0',
19
+ DevkitBuildAngular: '^20.2.1',
20
+ AngularBuild: '^20.2.1',
21
+ AngularSSR: '^20.2.1',
22
22
  };