Home / npm packages / vitest

vitest source code

Every file of vitest@5.0.3 as published on npm: 103 files, 2.8 MB. Search them by exact text or regex, in milliseconds.

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

What vitest uses

APIIn vitest
eval()
runs a string as JavaScript
NoWho does
new Function()
builds a function from a string, like eval (with or without new)
Yes: 1 file
e.g. dist/chunks/index.C4tKZ0yW.js
See the lines
child_process
starts other programs
Yes: 9 files
e.g. dist/chunks/cac.DfDGTQ9W.js
See the lines
process.env
reads environment variables
Yes: 16 files
e.g. dist/config.cjs
See the lines
the fs module
reads and writes files
Yes: 12 files
e.g. dist/chunks/cli-api.C4x4GGip.js
See the lines
http / https
makes or serves HTTP requests with Node's own modules
Yes: 2 files
e.g. dist/chunks/index.DpLw24bj.js
See the lines
fetch()
makes HTTP requests
Yes: 4 files
e.g. dist/chunks/index.DpLw24bj.js
See the lines
XMLHttpRequest
makes HTTP requests the old browser way
Yes: 1 file
e.g. dist/chunks/index.k8L_ZRzq.js
See the lines
crypto
hashes, encrypts or makes random numbers
Yes: 1 file
e.g. dist/chunks/index.DpLw24bj.js
See the lines
WebAssembly
loads WebAssembly code
Yes: 1 file
e.g. dist/chunks/vm.vTyZj_02.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
dist/chunks/index.DpLw24bj.js960 KB
dist/chunks/index.C4tKZ0yW.js321 KB
dist/chunks/acorn.C1kjbUFw.js219 KB
dist/chunks/run.BTlFXlnv.js166 KB
dist/chunks/plugin.d.BsjqSb4-.d.ts149 KB
dist/chunks/config.d.BxjInJat.d.ts136 KB
dist/chunks/cac.DfDGTQ9W.js99 KB
dist/chunks/nativeModuleRunner.jwZPY3dg.js63 KB
dist/chunks/source-map.DUxvo12T.js63 KB
dist/chunks/index.cx-_w29y.js57 KB
dist/chunks/vm.vTyZj_02.js53 KB
dist/chunks/index.k8L_ZRzq.js53 KB
dist/index.d.ts45 KB
LICENSE.md45 KB
dist/node.d.ts21 KB
dist/chunks/creator.203NYCo3.js20 KB
dist/chunks/doctor.CpHPRoza.js20 KB
dist/chunks/spy.DgMTfhrK.js19 KB
dist/chunks/cli-api.C4x4GGip.js19 KB
dist/module-evaluator.js17 KB
dist/chunks/init.D0qF-GGk.js17 KB
dist/chunks/pathe.M-eThtNZ.CknpM8Or.js15 KB
dist/chunks/base.DhkQeZwd.js9.4 KB
dist/chunks/nativeModuleMocker.CXSh3m91.js9.2 KB
dist/task-utils.js9.2 KB
dist/chunks/worker.d.Bt2A2mmi.d.ts9.0 KB
dist/chunks/index.ggMXe2IF.js7.7 KB
dist/chunks/utils.RcGwuOc_.js7.4 KB
dist/chunks/index.DXQx-kDM.js7.2 KB
dist/chunks/native.CBlba4VV.js6.8 KB

Questions

How many files are in vitest?

Version 5.0.3 of vitest publishes 103 files of source, 2.8 MB in all, not counting images, fonts and source maps.

Does vitest use eval?

No: vitest doesn't call eval() anywhere in its published files.

Does vitest start other programs?

Yes: vitest uses child_process in 9 of its files.

Does vitest run an install script?

No: vitest 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