(options: Schema)
| 3 | import { validateProject, validateBaseColor, installDependencies, setupTailwind, setupImportAliases } from './rules'; |
| 4 | |
| 5 | export function init(options: Schema): Rule { |
| 6 | return chain([ |
| 7 | (tree: Tree, context: SchematicContext) => { |
| 8 | const baseColor = options.baseColor || 'neutral'; |
| 9 | const project = options.project; |
| 10 | |
| 11 | // Log the user selections |
| 12 | context.logger.info('SlateUI Initialization Started'); |
| 13 | context.logger.info(`Project: ${project || '(default)'}`); |
| 14 | context.logger.info(`Base Color: ${baseColor}`); |
| 15 | |
| 16 | return tree; |
| 17 | }, |
| 18 | validateProject({ project: options.project }), |
| 19 | validateBaseColor({ baseColor: options.baseColor || 'neutral' }), |
| 20 | installDependencies(), |
| 21 | setupTailwind({ |
| 22 | project: options.project, |
| 23 | baseColor: options.baseColor || 'neutral', |
| 24 | confirmOverwrite: options.confirmOverwrite |
| 25 | }), |
| 26 | setupImportAliases(), |
| 27 | ]); |
| 28 | } |
nothing calls this directly
no test coverage detected