mirror of
https://github.com/angular/angular-cli.git
synced 2025-05-21 05:52:41 +08:00
refactor(@schematics/angular): remove deprecated options from app-shell and universal schematics
BREAKING CHANGE: The below options have been removed as they had no effect - `test` and `testTsconfigFileName` have been removed form the universal schematic - `universalProject`, `name`, `outDir`, `root` and `index` have been removed from the app-shell schematic
This commit is contained in:
parent
0fd3c550b5
commit
ac3aff20c0
@ -148,13 +148,7 @@ function addUniversalTarget(options: AppShellOptions): Rule {
|
|||||||
};
|
};
|
||||||
|
|
||||||
// Delete non-universal options.
|
// Delete non-universal options.
|
||||||
delete universalOptions.universalProject;
|
|
||||||
delete universalOptions.route;
|
delete universalOptions.route;
|
||||||
delete universalOptions.name;
|
|
||||||
delete universalOptions.outDir;
|
|
||||||
delete universalOptions.root;
|
|
||||||
delete universalOptions.index;
|
|
||||||
delete universalOptions.sourceDir;
|
|
||||||
|
|
||||||
return schematic('universal', universalOptions);
|
return schematic('universal', universalOptions);
|
||||||
};
|
};
|
||||||
|
@ -17,7 +17,6 @@ describe('App Shell Schematic', () => {
|
|||||||
require.resolve('../collection.json'),
|
require.resolve('../collection.json'),
|
||||||
);
|
);
|
||||||
const defaultOptions: AppShellOptions = {
|
const defaultOptions: AppShellOptions = {
|
||||||
name: 'foo',
|
|
||||||
clientProject: 'bar',
|
clientProject: 'bar',
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -13,74 +13,23 @@
|
|||||||
"$source": "projectName"
|
"$source": "projectName"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"universalProject": {
|
|
||||||
"type": "string",
|
|
||||||
"description": "The name of related Universal app.",
|
|
||||||
"x-deprecated": "This option has no effect."
|
|
||||||
},
|
|
||||||
"route": {
|
"route": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"description": "Route path used to produce the app shell.",
|
"description": "Route path used to produce the app shell.",
|
||||||
"default": "shell"
|
"default": "shell"
|
||||||
},
|
},
|
||||||
"name": {
|
|
||||||
"type": "string",
|
|
||||||
"format": "html-selector",
|
|
||||||
"description": "The HTML selector of the Universal app",
|
|
||||||
"x-deprecated": "This option has no effect."
|
|
||||||
},
|
|
||||||
"appId": {
|
"appId": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"format": "html-selector",
|
"format": "html-selector",
|
||||||
"description": "The app ID to use in withServerTransition().",
|
"description": "The app ID to use in withServerTransition().",
|
||||||
"default": "serverApp"
|
"default": "serverApp"
|
||||||
},
|
},
|
||||||
"outDir": {
|
|
||||||
"type": "string",
|
|
||||||
"format": "path",
|
|
||||||
"description": "The output directory for build results.",
|
|
||||||
"default": "dist-server",
|
|
||||||
"x-deprecated": "This option has no effect."
|
|
||||||
},
|
|
||||||
"root": {
|
|
||||||
"type": "string",
|
|
||||||
"format": "path",
|
|
||||||
"description": "The root directory of the app.",
|
|
||||||
"default": "src",
|
|
||||||
"x-deprecated": "This option has no effect."
|
|
||||||
},
|
|
||||||
"index": {
|
|
||||||
"type": "string",
|
|
||||||
"format": "path",
|
|
||||||
"description": "The name of the index file",
|
|
||||||
"default": "index.html",
|
|
||||||
"x-deprecated": "This option has no effect."
|
|
||||||
},
|
|
||||||
"main": {
|
"main": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"format": "path",
|
"format": "path",
|
||||||
"description": "The name of the main entry-point file.",
|
"description": "The name of the main entry-point file.",
|
||||||
"default": "main.server.ts"
|
"default": "main.server.ts"
|
||||||
},
|
},
|
||||||
"test": {
|
|
||||||
"type": "string",
|
|
||||||
"format": "path",
|
|
||||||
"description": "The name of the test entry-point file.",
|
|
||||||
"x-deprecated": "This option has no effect."
|
|
||||||
},
|
|
||||||
"tsconfigFileName": {
|
|
||||||
"type": "string",
|
|
||||||
"format": "path",
|
|
||||||
"default": "tsconfig.server",
|
|
||||||
"description": "The name of the TypeScript configuration file."
|
|
||||||
},
|
|
||||||
"testTsconfigFileName": {
|
|
||||||
"type": "string",
|
|
||||||
"format": "path",
|
|
||||||
"description": "The name of the TypeScript configuration file for tests.",
|
|
||||||
"default": "tsconfig.spec",
|
|
||||||
"x-deprecated": "This option has no effect."
|
|
||||||
},
|
|
||||||
"appDir": {
|
"appDir": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"format": "path",
|
"format": "path",
|
||||||
@ -99,13 +48,10 @@
|
|||||||
"description": "The name of the root module class.",
|
"description": "The name of the root module class.",
|
||||||
"default": "AppServerModule"
|
"default": "AppServerModule"
|
||||||
},
|
},
|
||||||
"sourceDir": {
|
"tsconfigFileName": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"format": "path",
|
"default": "tsconfig.server",
|
||||||
"description": "The path of the source directory.",
|
"description": "The name of the TypeScript configuration file."
|
||||||
"default": "src",
|
|
||||||
"alias": "D",
|
|
||||||
"x-deprecated": "This option has no effect."
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"required": [
|
"required": [
|
||||||
|
@ -21,24 +21,11 @@
|
|||||||
"description": "The name of the main entry-point file.",
|
"description": "The name of the main entry-point file.",
|
||||||
"default": "main.server.ts"
|
"default": "main.server.ts"
|
||||||
},
|
},
|
||||||
"test": {
|
|
||||||
"type": "string",
|
|
||||||
"format": "path",
|
|
||||||
"description": "The name of the test entry-point file.",
|
|
||||||
"x-deprecated": "This option has no effect."
|
|
||||||
},
|
|
||||||
"tsconfigFileName": {
|
"tsconfigFileName": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"default": "tsconfig.server",
|
"default": "tsconfig.server",
|
||||||
"description": "The name of the TypeScript configuration file."
|
"description": "The name of the TypeScript configuration file."
|
||||||
},
|
},
|
||||||
"testTsconfigFileName": {
|
|
||||||
"type": "string",
|
|
||||||
"format": "path",
|
|
||||||
"description": "The name of the TypeScript configuration file for tests.",
|
|
||||||
"default": "tsconfig.spec",
|
|
||||||
"x-deprecated": "This option has no effect."
|
|
||||||
},
|
|
||||||
"appDir": {
|
"appDir": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"format": "path",
|
"format": "path",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user