skilld-labs / skilld-docker-container

Starterkit for drupal development
MIT License
20 stars 32 forks source link

front.mk update for verbose #384

Closed koskinpark closed 3 years ago

koskinpark commented 3 years ago

https://webpack.js.org/configuration/stats/ verbose opt updated based on webpack5 docs

andypost commented 3 years ago

Maybe summary is better? Please provide sceenshots

koskinpark commented 3 years ago

tbh i have no idea why we need to display bundle information at all (no idea why default yarn build output not enough). I just replaced it with new webpack docs, coz we had verbose output earlier.

On my side such detailed output is useless (at least for the all past years i didn't investigate it at all), i guess until build is fast and correct, so)

summary provides no info almost: Screenshot from 2021-08-06 11-08-10

verbose provides everything about everything:

Click here
$ make front
grep: web/sites/default/settings.php: No such file or directory
- Theme directory found. Installing yarn dependencies...
lts-alpine: Pulling from library/node
Digest: sha256:0c80f9449d2690eef49aad35eeb42ed9f9bbe2742cd4e9766a7be3a1aae2a310
Status: Image is up to date for node:lts-alpine
docker.io/library/node:lts-alpine
v14.17.4
1.22.5
yarn install v1.22.5
[1/4] Resolving packages...
success Already up-to-date.
Done in 1.74s.
- Theme directory found. Building front assets...
lts-alpine: Pulling from library/node
Digest: sha256:0c80f9449d2690eef49aad35eeb42ed9f9bbe2742cd4e9766a7be3a1aae2a310
Status: Image is up to date for node:lts-alpine
docker.io/library/node:lts-alpine
v14.17.4
1.22.5
yarn run v1.22.5
$ cross-env ./node_modules/.bin/webpack --stats=verbose
Work with default basic options
PublicPath: auto
assets by path js/*.js 6.98 KiB
  asset js/app.js 6.39 KiB {143} [compared for emit] [minimized] (name: app)
  asset js/styles.js 571 bytes {532} [compared for emit] [minimized] (name: styles)
  asset js/sprite.js 28 bytes {400} [compared for emit] [minimized] (name: sprite)
asset svg/sprite.svg 1.21 KiB [compared for emit]
asset css/styles.css 810 bytes ({532}) [compared for emit] [from: ../css/styles.css] (auxiliary name: styles)
Entrypoint app 6.39 KiB = js/app.js
Entrypoint styles 571 bytes (810 bytes) = js/styles.js 1 auxiliary asset
Entrypoint sprite 28 bytes = js/sprite.js
chunk {143} (runtime: app) js/app.js (app) 24.4 KiB (javascript) 939 bytes (runtime) [entry] [rendered]
  > ./init.js app
  cacheable modules 24.4 KiB
    modules by path ../../node_modules/ 21.8 KiB
      ../../node_modules/focus-visible/dist/focus-visible.js [534] 11.2 KiB {143} [depth 2] [dependent] [built] [code generated]
        [used exports unknown]
        CommonJS bailout: this is used directly at 5:2-6
        Statement (ExpressionStatement) with side effects in source code at 1:0-312:5
        ModuleConcatenation bailout: Module is not an ECMAScript module
        cjs self exports reference [534] ../../node_modules/focus-visible/dist/focus-visible.js 5:2-6
        harmony side effect evaluation focus-visible ../../packages/components/helpers/focus-visible/h-focus-visible.js 6:0-23
        harmony side effect evaluation focus-visible [261] ./init.js + 2 modules ../../packages/components/helpers/focus-visible/h-focus-visible.js 6:0-23
      ../../node_modules/lodash.debounce/index.js [594] 10.5 KiB {143} [depth 2] [dependent] [built] [code generated]
        [used exports unknown]
        CommonJS bailout: module.exports is used directly at 377:0-14
        Statement (VariableDeclaration) with side effects in source code at 32:0-28
        ModuleConcatenation bailout: Module is not an ECMAScript module
        harmony side effect evaluation lodash.debounce ../../node_modules/@skilld/kaizen-breakpoints/index.js 1:0-39
        harmony import specifier lodash.debounce ../../node_modules/@skilld/kaizen-breakpoints/index.js 10:13-21
        cjs self exports reference [594] ../../node_modules/lodash.debounce/index.js 377:0-14
        harmony side effect evaluation lodash.debounce [261] ./init.js + 2 modules ../../node_modules/@skilld/kaizen-breakpoints/index.js 1:0-39
        harmony import specifier lodash.debounce [261] ./init.js + 2 modules ../../node_modules/@skilld/kaizen-breakpoints/index.js 10:13-21
    ../../packages/components/helpers/root-variables/h-root-variables.js [890] 392 bytes {143} [depth 1] [dependent] [built] [code generated]
      [no exports used]
      Statement (IfStatement) with side effects in source code at 6:0-16:1
      ModuleConcatenation bailout: Module is not an ECMAScript module
      harmony side effect evaluation @testtheme/components/helpers/root-variables/h-root-variables [261] ./init.js + 2 modules ./init.js 4:0-71
    ../../testtheme.breakpoints.yml [109] 541 bytes {143} [depth 1] [dependent] [built] [code generated]
      [used exports unknown]
      CommonJS bailout: module.exports is used directly at 1:0-14
      Statement (ExpressionStatement) with side effects in source code at 1:0-541
      ModuleConcatenation bailout: Module is not an ECMAScript module
      cjs self exports reference [109] ../../testtheme.breakpoints.yml 1:0-14
      harmony side effect evaluation ../../testtheme.breakpoints.yml [261] ./init.js + 2 modules ./init.js 2:0-53
      harmony import specifier ../../testtheme.breakpoints.yml [261] ./init.js + 2 modules ./init.js 6:26-32
      harmony import specifier ../../testtheme.breakpoints.yml [261] ./init.js + 2 modules ./init.js 7:25-31
    ./init.js + 2 modules [261] 1.7 KiB {143} [depth 0] [built] [code generated]
      [no exports]
      [no exports used]
      ModuleConcatenation bailout: Cannot concat with ../../testtheme.breakpoints.yml: Module is not an ECMAScript module
      ModuleConcatenation bailout: Cannot concat with ../../node_modules/focus-visible/dist/focus-visible.js: Module is not an ECMAScript module
      ModuleConcatenation bailout: Cannot concat with ../../node_modules/lodash.debounce/index.js: Module is not an ECMAScript module
      ModuleConcatenation bailout: Cannot concat with ../../packages/components/helpers/root-variables/h-root-variables.js: Module is not an ECMAScript module
      entry ./init.js app
  runtime modules 939 bytes
    webpack/runtime/compat get default export 302 bytes {143} [code generated]
      [no exports]
      [used exports unknown]
    webpack/runtime/define property getters 313 bytes {143} [code generated]
      [no exports]
      [used exports unknown]
    webpack/runtime/global 221 bytes {143} [code generated]
      [no exports]
      [used exports unknown]
    webpack/runtime/hasOwnProperty shorthand 103 bytes {143} [code generated]
      [no exports]
      [used exports unknown]
chunk {400} (runtime: sprite) js/sprite.js (sprite) 189 bytes [entry] [rendered]
  > /app/images/svg/test.svg sprite
  ../../images/svg/test.svg [585] 189 bytes {400} [depth 0] [built] [code generated]
    [exports: default]
    [no exports used]
    Statement (ExportDefaultDeclaration) with side effects in source code at 1:0-8:5
    entry /app/images/svg/test.svg sprite
chunk {532} (runtime: styles) js/styles.js (styles) 58 bytes (javascript) 1.07 KiB (runtime) [entry] [rendered]
  > /app/src/css/styles.css styles
  ../css/styles.css [808] 58 bytes {532} [depth 0] [built] [code generated]
    [exports: default]
    [no exports used]
    Statement (ExportDefaultDeclaration) with side effects in source code at 1:0-58
    entry /app/src/css/styles.css styles
  webpack/runtime/global 221 bytes {532} [code generated]
    [no exports]
    [used exports unknown]
  webpack/runtime/publicPath 875 bytes {532} [code generated]
    [no exports]
    [used exports unknown]

LOG from webpack.Compiler
 make hook: 1039.44958 ms
 finish make hook: 0.085348 ms
 finish compilation: 2.710507 ms
 seal compilation: 283.220912 ms
 afterCompile hook: 0.051282 ms
 emitAssets: 2.366996 ms
 emitRecords: 0.071867 ms
 done hook: 0.057347 ms
 beginIdle: 0.025957 ms

LOG from webpack.FlagDependencyExportsPlugin
 restore cached provided exports: 0.463412 ms
 figure out provided exports: 0.597497 ms
    56% of exports of modules have been determined (4 no declared exports, 5 not cached, 0 flagged uncacheable, 0 from cache, 0 additional calculations due to dependencies)
 store provided exports into cache: 0.240871 ms

LOG from webpack.InnerGraphPlugin
 infer dependency usage: 0.367953 ms

LOG from webpack.Compilation
 finish modules: 1.99116 ms
 report dependency errors and warnings: 0.422144 ms
 optimize dependencies: 2.027242 ms
 create chunks: 2.226366 ms
 optimize: 10.352819 ms
    7 modules hashed (0.78 variants per module in average)
 module hashing: 2.206443 ms
    100% code generated (7 generated, 0 from cache)
 code generation: 10.753407 ms
 runtime requirements: 2.508719 ms
 hashing: initialize hash: 0.005309 ms
 hashing: sort chunks: 0.094678 ms
 hashing: hash runtime modules: 1.439952 ms
 hashing: hash chunks: 2.026876 ms
 hashing: hash digest: 0.060362 ms
 hashing: process full hash modules: 0.002203 ms
 hashing: 4.130855 ms
    100% code generated (6 generated, 0 from cache)
 record hash: 0.033441 ms
 module assets: 0.319767 ms
 create chunk assets: 2.594431 ms
 process assets: 244.578643 ms

LOG from webpack.SideEffectsFlagPlugin
 update dependencies: 0.10578 ms

LOG from webpack.FlagDependencyUsagePlugin
 initialize exports usage: 0.072898 ms
 trace exports usage in graph: 1.287581 ms

LOG from webpack.buildChunkGraph
 visitModules: prepare: 0.235838 ms
 visitModules: visiting: 0.422585 ms
    18 queue items processed (9 blocks)
    0 chunk groups connected
    0 chunk groups processed for merging (0 module sets, 0 forked, 0 + 0 modules forked, 0 + 0 modules merged into fork, 0 resulting modules)
    0 chunk group info updated (0 already connected chunk groups reconnected)
 visitModules: 1.268784 ms
 connectChunkGroups: 0.065304 ms
 cleanup: 0.035077 ms

LOG from webpack.SplitChunksPlugin
 prepare: 0.020373 ms
 modules: 1.138754 ms
 queue: 0.00494 ms
 maxSize: 0.042088 ms

LOG from webpack.ModuleConcatenationPlugin
 select relevant modules: 0.263346 ms
 sort relevant modules: 0.020411 ms
 find modules to concatenate: 1.138535 ms
 sort concat configurations: 0.001674 ms
 create concatenated modules: 1.184105 ms
+ 3 hidden lines

LOG from webpack.FileSystemInfo
    9 new snapshots created
    0% root snapshot uncached (0 / 0)
    0% children snapshot uncached (0 / 0)
    0 entries tested
    File info in cache: 14 timestamps 14 hashes 14 timestamp hash combinations
    File timestamp hash combination snapshot optimization: 0% (0/14) entries shared via 0 shared snapshots (0 times referenced)
    Directory info in cache: 0 timestamps 0 hashes 0 timestamp hash combinations
    Managed items info in cache: 4 items
    Managed items snapshot optimization: 0% (0/4) entries shared via 0 shared snapshots (0 times referenced)
    Managed files snapshot optimization: 0% (0/4) entries shared via 0 shared snapshots (0 times referenced)

2021-08-06 05:08:34: webpack 5.40.0 compiled successfully in 1343 ms (fd520264e0e75d8f7da7)
Done in 2.07s.