Source

external interface Source(source)

Properties

Link copied to clipboard
abstract external var headers: ReadonlyRecord<String, String>?

Response headers added to every file served by this route. Headers computed by the file loader, including Content-Type, Content-Length, and Content-Range, will override these supplied values.

Link copied to clipboard
abstract external var index: String?

File served for a URL whose path ends in /. Defaults to index.html; an empty string disables it.

Link copied to clipboard
abstract external var root: String

Absolute path of the directory. The part of the URL's path after match.path is resolved inside it; paths that would leave it are not served. May point into an asar archive.

Link copied to clipboard
abstract external var type: String

Must be directory.