Skip to main content
Module

x/cav/mod.ts>ServeAssetOptions

A server framework for Deno
Go to Latest
interface ServeAssetOptions
Re-export
import { type ServeAssetOptions } from "https://deno.land/x/cav@0.0.21/mod.ts";

Options controlling how assets are found and served.

Properties

optional
cwd: string

Sets the current working directory when looking for assets. If a file:// path is provided, the parent folder of the path is used. This is useful if you want to serve assets relative to the current file using import.meta.url. Default: "."

optional
dir: string

The directory to serve assets from inside the cwd. This pattern encourages keeping public asset files separated from application source code, so that code isn't served by mistake. Default: "assets"

path: string

Path of the file to serve relative to the assets folder. (Required)