Home / File/ builtin.ts — vite Source File

builtin.ts — vite Source File

Architecture documentation for builtin.ts, a typescript file in the vite codebase. 0 imports, 2 dependents.

File typescript HMRClient HotRuntime 2 dependents 1 functions

Entity Profile

Dependency Diagram

graph LR
  58ae8bb3_1e86_ef80_62f2_c3c6b3a5d4dd["builtin.ts"]
  29e248d2_9983_1037_00e6_8bcd9ee87840["runner.ts"]
  29e248d2_9983_1037_00e6_8bcd9ee87840 --> 58ae8bb3_1e86_ef80_62f2_c3c6b3a5d4dd
  031bc221_67a8_c579_f2bf_bb30a08beeb2["utils.ts"]
  031bc221_67a8_c579_f2bf_bb30a08beeb2 --> 58ae8bb3_1e86_ef80_62f2_c3c6b3a5d4dd
  style 58ae8bb3_1e86_ef80_62f2_c3c6b3a5d4dd fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

export function createIsBuiltin(
  builtins: (string | RegExp)[],
): (id: string) => boolean {
  const plainBuiltinsSet = new Set(
    builtins.filter((builtin) => typeof builtin === 'string'),
  )
  const regexBuiltins = builtins.filter(
    (builtin) => typeof builtin !== 'string',
  )

  return (id: string) =>
    plainBuiltinsSet.has(id) || regexBuiltins.some((regexp) => regexp.test(id))
}

Domain

Subdomains

Functions

Frequently Asked Questions

What does builtin.ts do?
builtin.ts is a source file in the vite codebase, written in typescript. It belongs to the HMRClient domain, HotRuntime subdomain.
What functions are defined in builtin.ts?
builtin.ts defines 1 function(s): createIsBuiltin.
What files import builtin.ts?
builtin.ts is imported by 2 file(s): runner.ts, utils.ts.
Where is builtin.ts in the architecture?
builtin.ts is located at packages/vite/src/shared/builtin.ts (domain: HMRClient, subdomain: HotRuntime, directory: packages/vite/src/shared).

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free