yo icon indicating copy to clipboard operation
yo copied to clipboard

Move updateAvailableGenerators() elsewhere, try to make it stateless

Open sindresorhus opened this issue 9 years ago • 3 comments

https://github.com/yeoman/yo/blob/d40dbdfff32e335700bbed63f9953d32b5ae1072/lib/router.js#L52

// @SBoudrias

sindresorhus avatar Jan 08 '15 09:01 sindresorhus

I might be missing something, but what is the point of this.generators? It's created and assigned to but never used.

wtgtybhertgeghgtwtg avatar Nov 23 '16 23:11 wtgtybhertgeghgtwtg

Good point @wtgtybhertgeghgtwtg . Could anybody enlighten us here?

teobais avatar Nov 29 '17 00:11 teobais

Ah, routes are receiving the router instance as argument. It must be used in a route: https://github.com/yeoman/yo/blob/d40dbdfff32e335700bbed63f9953d32b5ae1072/lib/router.js#L35

SBoudrias avatar Nov 29 '17 11:11 SBoudrias