~/talk

Secret Tips to Improve Your Webpack Configuration

slides:none on file

Webpack runs with no config by default, supports running the config as TypeScript via ts-node, and accepts functions or async functions that receive env flags so builds change per flag. Multi-compiler mode builds multiple configs concurrently in one process (not parallel); parallel-webpack spawns real parallel workers. Nodemon restarts on config changes. Use require.resolve to validate paths, use .oneOf to stop multiple loader matches, prefer include over exclude, and use issuer or resourceQuery to apply different loaders. Webpack 5 adds an asset module type.

AI-written summary · about

  1. 0:00Intro
  2. 1:16ReactiveConf 2019 Secret Tips to Improve Your Webpack Config.
  3. 1:44You don't need a webpack config.
  4. 3:17TypeScript support.
  5. 5:36Function as config.
  6. 7:25Multi- compiler mode.
  7. 9:51#5 Async webpack configs.
  8. 14:30Use .filter (Boolean)
  9. 15:46Avoid config logic.
  10. 17:02Use module.rules [].oneOf.
  11. 19:24test for file extensions, include for absolute paths.
  12. 20:55"How to apply different loaders on the same module" Pt 1.
  13. 23:15#12 "How to apply different loaders on the same module" Pt 2.
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.