Home / npm packages / webpack

webpack source code

Every file of webpack@5.111.1 as published on npm: 887 files, 10.8 MB. Search them by exact text or regex, in milliseconds.

It uses: eval(), new Function(), child_process, process.env, the fs module, http / https, fetch(), crypto, WebAssembly.

What webpack uses

APIIn webpack
eval()
runs a string as JavaScript
Yes: 7 files
e.g. lib/EvalDevToolModulePlugin.js
See the lines
new Function()
builds a function from a string, like eval (with or without new)
Yes: 2 files
e.g. lib/util/binarySearchBounds.js
See the lines
child_process
starts other programs
Yes: 2 files
e.g. lib/node/nodeBuiltins.js
See the lines
process.env
reads environment variables
Yes: 10 files
e.g. lib/config/browserslistTargetHandler.js
See the lines
the fs module
reads and writes files
Yes: 2 files
e.g. lib/config/defaults.js
See the lines
http / https
makes or serves HTTP requests with Node's own modules
Yes: 3 files
e.g. lib/schemes/HttpUriPlugin.js
See the lines
fetch()
makes HTTP requests
Yes: 8 files
e.g. lib/web/FetchCompileAsyncWasmPlugin.js
See the lines
XMLHttpRequest
makes HTTP requests the old browser way
NoWho does
crypto
hashes, encrypts or makes random numbers
Yes: 2 files
e.g. lib/util/createHash.js
See the lines
WebAssembly
loads WebAssembly code
Yes: 11 files
e.g. lib/wasm-async/AsyncWasmCompileRuntimeModule.js
See the lines
document.cookie
reads or writes browser cookies
NoWho does
install scripts
runs a script when it's installed
NoWho does

Exact matches in the published files, so a mention in a comment counts too: open the lines to check.

Largest files

FileSize
types.d.ts836 KB
lib/css/syntax.js726 KB
lib/html/syntax.js522 KB
schemas/WebpackOptions.check.js413 KB
lib/javascript/syntax.js346 KB
schemas/WebpackOptions.json314 KB
lib/css/data.js269 KB
lib/javascript/JavascriptParser.js238 KB
lib/Compilation.js210 KB
lib/css/CssParser.js176 KB
lib/RuntimeTemplate.js170 KB
lib/javascript/grammar.js154 KB
lib/FileSystemInfo.js140 KB
lib/optimize/ConcatenatedModule.js110 KB
lib/stats/DefaultStatsFactoryPlugin.js91 KB
lib/config/defaults.js90 KB
README.md80 KB
lib/javascript/JavascriptModulesPlugin.js76 KB
lib/html/HtmlParser.js70 KB
lib/NormalModule.js69 KB
lib/NormalModuleFactory.js67 KB
lib/optimize/SplitChunksPlugin.js66 KB
lib/html/HtmlGenerator.js66 KB
lib/ChunkGraph.js63 KB
lib/ExportsInfo.js63 KB
lib/html/HtmlModulesPlugin.js61 KB
lib/dependencies/HarmonyExportImportedSpecifierDependency.js61 KB
lib/cache/PackFileCacheStrategy.js57 KB
lib/stats/DefaultStatsPrinterPlugin.js55 KB
lib/context/ContextModule.js54 KB

Questions

How many files are in webpack?

Version 5.111.1 of webpack publishes 887 files of source, 10.8 MB in all, not counting images, fonts and source maps.

Does webpack use eval?

Yes: webpack calls eval() in 7 of its files.

Does webpack start other programs?

Yes: webpack uses child_process in 2 of its files.

Does webpack run an install script?

No: webpack has no preinstall, install or postinstall script in its package.json.

npm packages that use…

Every package we've indexed →

Search your own code like this

The same engine answers over your documents and repositories: exact text and regex, every match counted, from your code or your AI agent.

See StackGrep Engine