Home / npm packages / prettier

prettier source code

Every file of prettier@3.9.9 as published on npm: 54 files, 7.7 MB. Search them by exact text or regex, in milliseconds.

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

What prettier uses

APIIn prettier
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. bin/prettier.cjs
See the lines
child_process
starts other programs
Yes: 2 files
e.g. plugins/typescript.js
See the lines
process.env
reads environment variables
Yes: 4 files
e.g. bin/prettier.cjs
See the lines
the fs module
reads and writes files
Yes: 4 files
e.g. internal/experimental-cli-worker.mjs
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: 2 files
e.g. internal/experimental-cli.mjs
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
plugins/typescript.js902 KB
plugins/typescript.mjs901 KB
index.mjs644 KB
internal/experimental-cli.mjs458 KB
THIRD-PARTY-NOTICES.md363 KB
plugins/babel.js319 KB
plugins/babel.mjs318 KB
plugins/markdown.js294 KB
plugins/markdown.mjs293 KB
internal/legacy-cli.mjs216 KB
plugins/estree.js213 KB
plugins/estree.mjs212 KB
plugins/html.js169 KB
plugins/html.mjs169 KB
plugins/postcss.js160 KB
plugins/postcss.mjs160 KB
plugins/acorn.js154 KB
plugins/acorn.mjs154 KB
plugins/yaml.mjs143 KB
plugins/glimmer.js140 KB
plugins/glimmer.mjs139 KB
plugins/yaml.js136 KB
plugins/angular.js133 KB
plugins/angular.mjs132 KB
plugins/meriyah.js127 KB
plugins/meriyah.mjs126 KB
internal/experimental-cli-worker.mjs89 KB
standalone.js82 KB
standalone.mjs82 KB
doc.js62 KB

Questions

How many files are in prettier?

Version 3.9.9 of prettier publishes 54 files of source, 7.7 MB in all, not counting images, fonts and source maps.

Does prettier use eval?

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

Does prettier start other programs?

Yes: prettier uses child_process in 2 of its files.

Does prettier run an install script?

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