2 const schematic_command_1 = require("@angular/cli/models/schematic-command");
3 const project_1 = require("@angular/cli/utilities/project");
4 const schematicsProvider = (async function () {
5 let workspace = await project_1.getWorkspaceDetails();
6 let command = new schematic_command_1.SchematicCommand({ workspace: workspace }, null, null);
7 let { listSchematicNames } = (await command.createWorkflow({ interactive: false })).engineHost;
8 let defaultSchematicCollection = await command.getDefaultSchematicCollection();
10 getCollection(collectionName) {
11 return command.getCollection(collectionName);
13 listSchematics(collection) {
14 return listSchematicNames(collection.description);
16 getSchematic(collection, schematicName, allowPrivate) {
17 return command.getSchematic(collection, schematicName, allowPrivate);
19 getDefaultSchematicCollection() {
20 return defaultSchematicCollection;
24 module.exports = schematicsProvider;