koa2-static
v1.0.1
Published
static serve middleware for koa2
Downloads
56
Readme
koa2-static
Koa2 middleware for serving static files.
Install
npm install koa2-static
Usage
import Koa from "koa"
import static from "koa2-static"
const app = new Koa()
app.use(static({
path: "/web",
root: __dirname + "/assets"
}));
app.listen(8000)
Options
root
{string} directory that is to be servedpath
{string} url base path
Others see koa-send