Module

x/ultra/lib/build/deps.ts>Builder

🧙 Hypermodern Zero-Legacy Deno/React Framework
Go to Latest
class Builder
import { Builder } from "https://dotland.deno.dev/x/ultra@v2.0.0-beta.9/lib/build/deps.ts";

Constructors

new
Builder(context: BuildContext)

Properties

compiled: RegExp[]
dynamicImportIgnored: RegExp[]
entrypoints: Map<string, Entrypoint>
hashed: RegExp[]
ignored: RegExp[]
importMap: ImportMap
log: Logger

Methods

addEntrypoint(name: string, config: EntrypointConfig)
build(buildSources: FileBag): Promise<BuildResult>
compileSource(source: IFile): Promise<IFile>
copySource(source: IFile, destination?: string)
copySources(sources: FileBag, destination?: string)
gatherSources(from?: string)

Walk the root for SourceFiles obeying exclusion patterns

getEntrypoint(name: string)
globToRegExp(pattern: string, options?: GlobToRegExpOptions)

Returns a Map with the key being the original relative path and the value being the content hashed relative path.

isCompilable(source: IFile): boolean
isHashable(source: IFile): boolean
isIgnored(source: IFile): boolean
setCompiled(paths: string[])
setDynamicImportIgnored(paths: string[])
setEntrypoints(entrypoints: BuilderEntrypoints)
setHashed(paths: string[])
setIgnored(paths: string[])

Allows ignoring certain files from the build process, they won't be copied to the build output directory, so no further processing will occur on them.

toManifest(sources: FileBag, unnamed 1?: { ignore?: string[]; prefix?: string; } | undefined)