Home / Function/ equalWithoutSuffix() — vite Function Reference

equalWithoutSuffix() — vite Function Reference

Architecture documentation for the equalWithoutSuffix() function in resolve.ts from the vite codebase.

Entity Profile

Dependency Diagram

graph TD
  251e65d5_721b_49e6_292d_16474dee6a4a["equalWithoutSuffix()"]
  dcff87b0_a8ea_57a2_3b29_a7b8f19986f3["resolve.ts"]
  251e65d5_721b_49e6_292d_16474dee6a4a -->|defined in| dcff87b0_a8ea_57a2_3b29_a7b8f19986f3
  8ff08c93_2e0c_c3ed_bfd0_267a77f07273["mapWithBrowserField()"]
  8ff08c93_2e0c_c3ed_bfd0_267a77f07273 -->|calls| 251e65d5_721b_49e6_292d_16474dee6a4a
  style 251e65d5_721b_49e6_292d_16474dee6a4a fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/vite/src/node/plugins/resolve.ts lines 1184–1186

function equalWithoutSuffix(path: string, key: string, suffix: string) {
  return key.endsWith(suffix) && key.slice(0, -suffix.length) === path
}

Domain

Subdomains

Frequently Asked Questions

What does equalWithoutSuffix() do?
equalWithoutSuffix() is a function in the vite codebase, defined in packages/vite/src/node/plugins/resolve.ts.
Where is equalWithoutSuffix() defined?
equalWithoutSuffix() is defined in packages/vite/src/node/plugins/resolve.ts at line 1184.
What calls equalWithoutSuffix()?
equalWithoutSuffix() is called by 1 function(s): mapWithBrowserField.

Analyze Your Own Codebase

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

Try Supermodel Free