{"id":13799285,"url":"https://github.com/koa-modules/serve-list","last_synced_at":"2025-05-16T16:31:15.209Z","repository":{"id":29792145,"uuid":"33336367","full_name":"koa-modules/serve-list","owner":"koa-modules","description":"Serve directory listings for koa, based on Express's serve-index.","archived":false,"fork":false,"pushed_at":"2015-12-30T02:19:38.000Z","size":15,"stargazers_count":7,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-04-25T22:05:36.762Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/koa-modules.png","metadata":{"files":{"readme":"README.md","changelog":"History.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-04-02T23:14:04.000Z","updated_at":"2022-05-21T14:07:30.000Z","dependencies_parsed_at":"2022-09-03T12:22:50.351Z","dependency_job_id":null,"html_url":"https://github.com/koa-modules/serve-list","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/koa-modules%2Fserve-list","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/koa-modules%2Fserve-list/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/koa-modules%2Fserve-list/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/koa-modules%2Fserve-list/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/koa-modules","download_url":"https://codeload.github.com/koa-modules/serve-list/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254567328,"owners_count":22092750,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-04T00:01:00.714Z","updated_at":"2025-05-16T16:31:14.928Z","avatar_url":"https://github.com/koa-modules.png","language":"JavaScript","readme":"# koa-serve-list\n\n\u003e Serves pages that contain directory listings for a given path for koa.  \n\u003e [serve-index] wrapper for koa's middleware.\n\n[![NPM version][npm-img]][npm-url]\n[![NPM Downloads][downloads-image]][npm-url]\n[![Build status][travis-img]][travis-url]\n[![Test coverage][coveralls-img]][coveralls-url]\n[![Dependency status][david-img]][david-url]\n[![License][license-img]][license-url]\n\n## Install\n\n```sh\n$ npm install --save koa-serve-list\n```\n\n## Usage\n\n### **=1.x**, 100%, working with `koa-v2`\n\n```js\nconst Koa = require('koa');\nconst serveList = require('koa-serve-list');\nconst serveStatic = require('koa-serve-static');\nconst app = new Koa();\n\napp.use(serveList(path, options));\napp.use(serveStatic(root, options));\n\napp.listen(3000);\n```\n\n### **\u003c1.x**\n\n```js\nvar koa = require('koa');\nvar serveList = require('koa-serve-list');\nvar serveStatic = require('koa-serve-static');\nvar app = koa();\n\napp.use(serveList(path, options));\napp.use(serveStatic(root, options));\n\napp.listen(3000);\n```\n\n[npm-img]: https://img.shields.io/npm/v/koa-serve-list.svg?style=flat-square\n[npm-url]: https://npmjs.org/package/koa-serve-list\n[travis-img]: https://img.shields.io/travis/koa-modules/serve-list.svg?style=flat-square\n[travis-url]: https://travis-ci.org/koa-modules/serve-list\n[coveralls-img]: https://img.shields.io/coveralls/koa-modules/serve-list.svg?style=flat-square\n[coveralls-url]: https://coveralls.io/r/koa-modules/serve-list?branch=master\n[license-img]: https://img.shields.io/badge/license-MIT-green.svg?style=flat-square\n[license-url]: LICENSE\n[david-img]: https://img.shields.io/david/koa-modules/serve-list.svg?style=flat-square\n[david-url]: https://david-dm.org/koa-modules/serve-list\n[downloads-image]: https://img.shields.io/npm/dm/koa-serve-list.svg?style=flat-square\n[serve-index]: https://github.com/expressjs/serve-index\n","funding_links":[],"categories":["仓库"],"sub_categories":["中间件"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkoa-modules%2Fserve-list","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkoa-modules%2Fserve-list","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkoa-modules%2Fserve-list/lists"}