Problem
In packages/cli/src/commands/generate/yargsHandlerHelpers.js, two TODOs mark code that was meant to be temporary during the CLI refactor:
Line 23:
// TODO: Remove this import. This is only temporarily to be able to split one
// command at a time into a separate async handler
import {
createCommand,
createDescription,
createBuilder,
} from './yargsCommandHelpers.js'
Line 207:
// TODO: Remove this function. This is only temporarily to be able to split one
// command at a time into a separate async handler
export const createYargsForComponentGeneration = ({ ... }) => { ... }
The migration is now complete. No production command uses createYargsForComponentGeneration — every generator (cell, page, component, directive, job, function, etc.) now has its own *Handler.js file. Several of them even have comments like // This could be built using createYargsForComponentGeneration confirming they deliberately did not use it.
The only consumer of createYargsForComponentGeneration is the test file:
packages/cli/src/commands/generate/__tests__/createYargsForComponentGeneration.test.js
Fix
- Remove the
createCommand, createDescription, createBuilder import from yargsHandlerHelpers.js (lines 23–29)
- Remove the
createYargsForComponentGeneration export from yargsHandlerHelpers.js (lines 207–248)
- Delete the test file
__tests__/createYargsForComponentGeneration.test.js
No other files need updating — nothing imports createYargsForComponentGeneration outside of that test.
Files to change
packages/cli/src/commands/generate/yargsHandlerHelpers.js — remove import (lines 23–29) and function (lines 207–248)
packages/cli/src/commands/generate/__tests__/createYargsForComponentGeneration.test.js — delete
Problem
In
packages/cli/src/commands/generate/yargsHandlerHelpers.js, two TODOs mark code that was meant to be temporary during the CLI refactor:Line 23:
Line 207:
The migration is now complete. No production command uses
createYargsForComponentGeneration— every generator (cell, page, component, directive, job, function, etc.) now has its own*Handler.jsfile. Several of them even have comments like// This could be built using createYargsForComponentGenerationconfirming they deliberately did not use it.The only consumer of
createYargsForComponentGenerationis the test file:packages/cli/src/commands/generate/__tests__/createYargsForComponentGeneration.test.jsFix
createCommand,createDescription,createBuilderimport fromyargsHandlerHelpers.js(lines 23–29)createYargsForComponentGenerationexport fromyargsHandlerHelpers.js(lines 207–248)__tests__/createYargsForComponentGeneration.test.jsNo other files need updating — nothing imports
createYargsForComponentGenerationoutside of that test.Files to change
packages/cli/src/commands/generate/yargsHandlerHelpers.js— remove import (lines 23–29) and function (lines 207–248)packages/cli/src/commands/generate/__tests__/createYargsForComponentGeneration.test.js— delete