UNPKG

@prostory/mountain

Version:

Yet another HTTP/2 server and client.

3 lines (2 loc) 381 B
import{resolve as r}from"path";import{normalize as o}from"../utils/url.js";import{get as s}from"../route.js";import{responseFor as t}from"../plugins/response.js";import{accessRequest as i}from"../plugins/access.js";const m=/.+\.\w[\w\d]*$/,p=(p="")=>s(o(String(m)),(o=>{const{url:s}=i(o);t(o).file(r(p,s.pathname.slice(1)))}));export{p as files}; //# sourceMappingURL=files.js.map