@farmfe/core
Version:
Farm is a extremely fast web build tool written in Rust. Farm can start a project in milliseconds and perform HMR within 10ms, making it much faster than similar tools like webpack and vite.
25 lines (24 loc) • 913 B
TypeScript
/**
* The following is modified based on source found in
* https://github.com/vitejs/vite
*
* MIT Licensed
* Copyright (c) 2019-present, (Evan) You and Vite contributors
* https://github.com/vitejs/vite/blob/main/LICENSE
*/
/// <reference types="node" resolution-mode="require"/>
import type { Server } from 'node:net';
import { UserServerConfig } from '../index.js';
export interface ResolvedServerUrls {
local: string[];
network: string[];
}
export interface Hostname {
host: string | undefined;
name: string;
}
export declare const urlRegex: RegExp;
export declare const loopbackHosts: Set<string>;
export declare const wildcardHosts: Set<string>;
export declare function resolveServerUrls(server: Server, options: UserServerConfig, publicPath?: string): Promise<ResolvedServerUrls>;
export declare function resolveHostname(optionsHost: string | boolean | undefined): Promise<Hostname>;