{"name":"serve","version":"14.2.6","description":"Static file serving and directory listing","keywords":["vercel","serve","micro","http-server"],"repository":{"type":"git","url":"git+https://github.com/vercel/serve.git"},"license":"MIT","type":"module","bin":{"serve":"build/main.js"},"engines":{"node":">= 14"},"dependencies":{"@zeit/schemas":"2.36.0","ajv":"8.18.0","arg":"5.0.2","boxen":"7.0.0","chalk":"5.0.1","chalk-template":"0.4.0","clipboardy":"3.0.0","compression":"1.8.1","is-port-reachable":"4.0.0","serve-handler":"6.1.7","update-check":"1.5.4"},"devDependencies":{"@changesets/cli":"2.29.6","@types/compression":"1.7.2","@types/serve-handler":"6.1.1","@vercel/style-guide":"3.0.0","@vitest/coverage-v8":"2.1.3","eslint":"8.19.0","got":"12.1.0","husky":"8.0.1","lint-staged":"13.0.3","prettier":"2.7.1","tsup":"8.3.0","tsx":"4.19.1","typescript":"5.6.3","vitest":"2.1.3"},"tsup":{"target":"esnext","format":["esm"],"outDir":"./build/"},"prettier":"@vercel/style-guide/prettier","eslintConfig":{"extends":["./node_modules/@vercel/style-guide/eslint/node.js","./node_modules/@vercel/style-guide/eslint/typescript.js"],"parserOptions":{"project":"tsconfig.json"}},"lint-staged":{"*":["prettier --ignore-unknown --write"],"source/**/*.ts":["eslint --max-warnings 0 --fix","vitest related --run"],"tests":["vitest --run"]},"scripts":{"develop":"tsx watch ./source/main.ts","start":"node ./build/main.js","compile":"tsup ./source/main.ts","test:tsc":"tsc --project tsconfig.json","test:unit":"vitest run --config config/vitest.ts","test:watch":"vitest watch --config config/vitest.ts","test":"pnpm test:tsc && pnpm test:unit","lint:code":"eslint --max-warnings 0 source/**/*.ts","lint:style":"prettier --check --ignore-path .gitignore .","lint":"pnpm lint:code && pnpm lint:style","format":"prettier --write --ignore-path .gitignore .","changeset":"changeset","version-packages":"changeset version","release":"pnpm compile && changeset publish"},"_id":"serve@14.2.6","bugs":{"url":"https://github.com/vercel/serve/issues"},"homepage":"https://github.com/vercel/serve#readme","_integrity":"sha512-QEjUSA+sD4Rotm1znR8s50YqA3kYpRGPmtd5GlFxbaL9n/FdUNbqMhxClqdditSk0LlZyA/dhud6XNRTOC9x2Q==","_resolved":"/tmp/567ae5bd4d6bbebf2bb06e4e8cabf5ab/serve-14.2.6.tgz","_from":"file:serve-14.2.6.tgz","_nodeVersion":"22.22.0","_npmVersion":"10.9.4","dist":{"integrity":"sha512-QEjUSA+sD4Rotm1znR8s50YqA3kYpRGPmtd5GlFxbaL9n/FdUNbqMhxClqdditSk0LlZyA/dhud6XNRTOC9x2Q==","shasum":"b5e520dfda9b1ed3b824a8e8d4fd6f69e4c6944c","tarball":"http://registry-npm.ywwl.com/serve/download/serve-14.2.6.tgz","fileCount":4,"unpackedSize":25990,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCICin4C4TpzLgI39ATYk9BPglcx3Y1dd9R7Fls6zBBJUZAiEAmYC8IEdW3yQO9CW0wWutJ7NM7xub7sHnao58wL+dhQs="}],"size":8807,"noattachment":false,"key":"/serve/-/serve-14.2.6.tgz"},"_npmUser":{"name":"vercel-release-bot","email":"infra+release@vercel.com"},"directories":{},"maintainers":[{"name":"rauchg","email":"rauchg@gmail.com"},{"name":"timneutkens","email":"tim@vercel.com"},{"name":"vercel-release-bot","email":"infra+release@vercel.com"},{"name":"zeit-bot","email":"team@zeit.co"},{"name":"leo","email":"mindrun@icloud.com"},{"name":"arunoda","email":"arunoda.susiripala@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/serve_14.2.6_1772564694910_0.6783518840302278"},"_hasShrinkwrap":false,"readme":"![Serve Logo](https://raw.githubusercontent.com/vercel/serve/main/media/banner.png)\n\n<div align=\"center\">\n  <a aria-label=\"Vercel logo\" href=\"https://vercel.com\">\n    <img src=\"https://img.shields.io/badge/made%20by-vercel-%23000000\">\n  </a>\n  <br>\n  <a aria-label=\"Install Size\" href=\"https://packagephobia.com/result?p=serve\">\n    <img src=\"https://packagephobia.com/badge?p=serve\">\n  </a>\n  <a aria-label=\"Stars\" href=\"https://github.com/vercel/serve/stargazers\">\n    <img src=\"https://img.shields.io/github/stars/vercel/serve\">\n  </a>\n  <a aria-label=\"Build Status\" href=\"https://github.com/vercel/serve/actions/workflows/ci.yaml\">\n    <img src=\"https://github.com/vercel/serve/actions/workflows/ci.yaml/badge.svg\">\n  </a>\n</div>\n\n---\n\n`serve` helps you serve a static site, single page application or just a static file (no matter if on your device or on the local network). It also provides a neat interface for listing the directory's contents:\n\n![Listing UI](https://raw.githubusercontent.com/vercel/serve/main/media/listing-ui.png)\n\n> Once it's time to push your site to production, we recommend using [Vercel](https://vercel.com).\n\n## Usage\n\n> `serve` v14 onwards requires Node v14 to run. Please use `serve` v13 if you cannot upgrade to Node v14.\n\nThe quickest way to get started is to just run `npx serve` in your project's directory.\n\nIf you prefer, you can also install the package globally (you'll need at least [Node LTS](https://github.com/nodejs/Release#release-schedule)):\n\n```bash\n> npm install --global serve\n```\n\nOnce that's done, you can run this command inside your project's directory...\n\n```bash\n> serve\n```\n\n...or specify which folder you want to serve:\n\n```bash\n> serve folder-name/\n```\n\nFinally, run this command to see a list of all available options:\n\n```bash\n> serve --help\n```\n\nNow you understand how the package works! :tada:\n\n## Configuration\n\nTo customize `serve`'s behavior, create a `serve.json` file in the public folder and insert any of [these properties](https://github.com/vercel/serve-handler#options).\n\n## API\n\nThe core of `serve` is [`serve-handler`](https://github.com/vercel/serve-handler), which can be used as middleware in existing HTTP servers:\n\n```js\nconst handler = require('serve-handler');\nconst http = require('http');\n\nconst server = http.createServer((request, response) => {\n  // You pass two more arguments for config and middleware\n  // More details here: https://github.com/vercel/serve-handler#options\n  return handler(request, response);\n});\n\nserver.listen(3000, () => {\n  console.log('Running at http://localhost:3000');\n});\n```\n\n> You can also replace `http.createServer` with [`micro`](https://github.com/vercel/micro).\n\n## Issues and Contributing\n\nIf you want a feature to be added, or wish to report a bug, please open an issue [here](https://github.com/vercel/serve/issues/new).\n\nIf you wish to contribute to the project, please read the [contributing guide](contributing.md) first.\n\n## Credits\n\nThis project used to be called `list` and `micro-list`. But thanks to [TJ Holowaychuk](https://github.com/tj) handing us the new name, it's now called `serve` (which is much more definite).\n\n## Author\n\nLeo Lamprecht ([@leo](https://x.com/leo))\n","publish_time":1772564695061,"_cnpm_publish_time":1772564695061,"dist-tags":{"latest":"14.2.8","snapshot":"14.2.5-ac84c2e7-20250904133617"}}