Home / npm packages / zod

zod source code

Every file of zod@4.6.5 as published on npm: 840 files, 6.1 MB. Search them by exact text or regex, in milliseconds.

It uses: new Function(), the fs module, crypto.

What zod uses

APIIn zod
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. src/v4/classic/tests/jitless-allows-eval.test.ts
See the lines
child_process
starts other programs
NoWho does
process.env
reads environment variables
NoWho does
the fs module
reads and writes files
Yes: 1 file
e.g. src/v4/core/tests/locales/parity.test.ts
See the lines
http / https
makes or serves HTTP requests with Node's own modules
NoWho does
fetch()
makes HTTP requests
NoWho does
XMLHttpRequest
makes HTTP requests the old browser way
NoWho does
crypto
hashes, encrypts or makes random numbers
Yes: 1 file
e.g. src/v4/classic/tests/string.test.ts
See the lines
WebAssembly
loads WebAssembly code
NoWho does
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
src/v4/core/schemas.ts176 KB
src/v3/types.ts160 KB
src/v4/classic/tests/to-json-schema.test.ts145 KB
v3/types.cjs141 KB
v3/types.js131 KB
v4/core/schemas.cjs110 KB
v4/core/schemas.js106 KB
src/v4/classic/schemas.ts103 KB
src/v4/core/compile.ts97 KB
v4/core/compile.cjs94 KB
v4/core/compile.js92 KB
src/v4/classic/tests/string.test.ts91 KB
src/v4/core/tests/compile.test.ts72 KB
src/v3/tests/string.test.ts66 KB
src/v4/mini/schemas.ts65 KB
v4/classic/schemas.cjs59 KB
v4/core/schemas.d.cts59 KB
v4/core/schemas.d.ts59 KB
src/v4/core/api.ts58 KB
v4/classic/schemas.js53 KB
v3/types.d.cts52 KB
v3/types.d.ts52 KB
v4/classic/schemas.d.cts52 KB
v4/classic/schemas.d.ts52 KB
src/v4/classic/tests/from-json-schema.test.ts50 KB
src/v4/core/util.ts48 KB
v4/core/json-schema-processors.cjs41 KB
v4/classic/from-json-schema.cjs40 KB
src/v4/core/tests/compile-differential.test.ts40 KB
src/v4/core/checks.ts39 KB

Questions

How many files are in zod?

Version 4.6.5 of zod publishes 840 files of source, 6.1 MB in all, not counting images, fonts and source maps.

Does zod use eval?

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

Does zod start other programs?

No: zod doesn't use child_process anywhere in its published files.

Does zod run an install script?

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