/**
 * Static file serving for Effect HTTP applications.
 *
 * `HttpStaticServer` turns HTTP requests into file responses rooted at a
 * configured directory. Use {@link make} when you need an application value, or
 * {@link layer} when static files should be mounted onto an `HttpRouter`,
 * optionally under a URL prefix.
 *
 * **Mental model**
 *
 * The request path is decoded, normalized, and resolved below `root`. Invalid
 * paths, null bytes, and `..` traversal outside `root` fail as route-not-found
 * errors. A matching file is served through `HttpPlatform.fileResponse`, a
 * matching directory serves `index` when configured, and `spa: true` falls back
 * to the index file for extensionless HTML requests.
 *
 * **Common tasks**
 *
 * - Serve a public assets directory with {@link make}
 * - Mount static assets beside API routes with {@link layer}
 * - Add `Cache-Control` headers with `cacheControl`
 * - Extend MIME type detection with `mimeTypes`
 * - Support single-page application routing with `spa: true`
 *
 * **Gotchas**
 *
 * - {@link layer} installs `GET` routes only; handle other methods elsewhere.
 * - Dotfiles are served when they live under `root`; keep secrets outside the
 *   served tree.
 * - Symlinks or generated files reachable from `root` may expose more than
 *   expected.
 * - Conditional requests and byte ranges depend on metadata supplied by
 *   `HttpPlatform`.
 *
 * @since 4.0.0
 */
import * as Effect from "../../Effect.ts";
import * as FileSystem from "../../FileSystem.ts";
import * as Layer from "../../Layer.ts";
import * as Path from "../../Path.ts";
import type { PlatformError } from "../../PlatformError.ts";
import * as HttpPlatform from "./HttpPlatform.ts";
import * as HttpRouter from "./HttpRouter.ts";
import * as HttpServerError from "./HttpServerError.ts";
import * as HttpServerRequest from "./HttpServerRequest.ts";
import * as HttpServerResponse from "./HttpServerResponse.ts";
/**
 * Creates an `HttpApp` that serves files from a directory.
 *
 * **Example** (Serving files from a directory)
 *
 * ```ts
 * import { Effect } from "effect"
 * import { HttpStaticServer } from "effect/unstable/http"
 *
 * const program = Effect.gen(function*() {
 *   const app = yield* HttpStaticServer.make({ root: "./public" })
 *   return app
 * })
 * ```
 *
 * @category constructors
 * @since 4.0.0
 */
export declare const make: (options: {
    readonly root: string;
    readonly index?: string | undefined;
    readonly spa?: boolean | undefined;
    readonly cacheControl?: string | undefined;
    readonly mimeTypes?: Record<string, string> | undefined;
}) => Effect.Effect<Effect.Effect<HttpServerResponse.HttpServerResponse, HttpServerError.HttpServerError, HttpServerRequest.HttpServerRequest>, PlatformError, FileSystem.FileSystem | Path.Path | HttpPlatform.HttpPlatform>;
/**
 * Creates a layer that mounts static files on an `HttpRouter`.
 *
 * **Example** (Mounting static files on a router)
 *
 * ```ts
 * import { Layer } from "effect"
 * import { HttpRouter, HttpServerResponse, HttpStaticServer } from "effect/unstable/http"
 *
 * const ApiLayer = HttpRouter.add("GET", "/health", HttpServerResponse.text("ok"))
 *
 * const StaticFilesLayer = HttpStaticServer.layer({
 *   root: "./public",
 *   prefix: "/static"
 * })
 *
 * const AppLayer = Layer.mergeAll(ApiLayer, StaticFilesLayer)
 * ```
 *
 * @category layers
 * @since 4.0.0
 */
export declare const layer: (options: {
    readonly root: string;
    readonly index?: string | undefined;
    readonly spa?: boolean | undefined;
    readonly cacheControl?: string | undefined;
    readonly mimeTypes?: Record<string, string> | undefined;
    readonly prefix?: string | undefined;
}) => Layer.Layer<never, PlatformError, HttpRouter.HttpRouter | FileSystem.FileSystem | Path.Path | HttpPlatform.HttpPlatform>;
//# sourceMappingURL=HttpStaticServer.d.ts.map