Skip to main content
Module

x/iterable_file_server/mod.ts>serve

Serve items from `AsyncIterable<File>`
Latest
function serve
import { serve } from "https://deno.land/x/iterable_file_server@v0.2.0/mod.ts";

Serves the items from the async iterable of the files matching by its file name.

ex. If file.name === "foo.txt", it's served at url "http://localhost:3000/foo.txt". If file.name === "foo/bar.html", it's served at url "http://localhost:3000/foo/bar.html".

Parameters

src: AsyncIterable<File>
optional
unnamed 1: ServeOptions = [UNSUPPORTED]

Returns

Server