Commit c3ca150
committed
perf(webpack-cli): defer CLI require until after local-install check
bin/cli.js required both `import-local` and the full CLI implementation
up front. Reorder so:
- a run delegated to a local install returns without loading the outer
installation's CLI lib (+commander), and
- WEBPACK_CLI_SKIP_IMPORT_LOCAL short-circuits before requiring
`import-local` at all (10 fewer modules loaded on that path).
The typical local invocation is unchanged. Behavior is preserved
(import-local still runs by default).
https://claude.ai/code/session_01TKJqMqs6zkot18iBUae52n1 parent 6e1e3fc commit c3ca150
2 files changed
Lines changed: 14 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
6 | 14 | | |
7 | 15 | | |
8 | 16 | | |
| |||
16 | 24 | | |
17 | 25 | | |
18 | 26 | | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | 27 | | |
29 | 28 | | |
0 commit comments