UNPKG

rgen-cli

Version:

A developer CLI for initializing React projects, managing utilities, and scaffolding components, hooks, pages, layouts, routes, and contexts quickly.

17 lines (16 loc) 588 B
import { Args, Command, Flags } from '@oclif/core'; import Layout from '../../libs/build-layout.js'; export default class MakeLayout extends Command { static args = { name: Args.string({ description: 'Name of the layout', required: true }), }; static description = 'Generate a React layout'; static flags = { desc: Flags.string({ description: 'AI description for React layout.' }), }; async run() { const { args, flags } = await this.parse(MakeLayout); const c = new Layout(this, args.name, flags); await c.setup(); } }