Home / File/ types.ts — vue Source File

types.ts — vue Source File

Architecture documentation for types.ts, a typescript file in the vue codebase. 3 imports, 9 dependents.

File typescript CompilerSFC 3 imports 9 dependents

Entity Profile

Dependency Diagram

graph LR
  1502a238_61f0_9afa_8c3c_71d2bb769820["types.ts"]
  ecb7777f_63cc_7bf6_1f6a_fedf933d43a4["parseComponent.ts"]
  1502a238_61f0_9afa_8c3c_71d2bb769820 --> ecb7777f_63cc_7bf6_1f6a_fedf933d43a4
  723c94a2_276b_7491_3957_5f4e8a659b73["SFCDescriptor"]
  1502a238_61f0_9afa_8c3c_71d2bb769820 --> 723c94a2_276b_7491_3957_5f4e8a659b73
  47ae9f26_59d1_fab2_349f_966f5d15495a["compiler"]
  1502a238_61f0_9afa_8c3c_71d2bb769820 --> 47ae9f26_59d1_fab2_349f_966f5d15495a
  b9f12a63_b611_1b00_0717_3ff21d7ce156["compileScript.ts"]
  b9f12a63_b611_1b00_0717_3ff21d7ce156 --> 1502a238_61f0_9afa_8c3c_71d2bb769820
  ff52d56b_a346_9a70_961a_c5aca0690626["compileTemplate.ts"]
  ff52d56b_a346_9a70_961a_c5aca0690626 --> 1502a238_61f0_9afa_8c3c_71d2bb769820
  b08241c7_738d_9e08_b885_fad82facd4f3["cssVars.ts"]
  b08241c7_738d_9e08_b885_fad82facd4f3 --> 1502a238_61f0_9afa_8c3c_71d2bb769820
  c09840ce_bc86_fdc3_93a1_cf7e368a9a93["parse.ts"]
  c09840ce_bc86_fdc3_93a1_cf7e368a9a93 --> 1502a238_61f0_9afa_8c3c_71d2bb769820
  ecb7777f_63cc_7bf6_1f6a_fedf933d43a4["parseComponent.ts"]
  ecb7777f_63cc_7bf6_1f6a_fedf933d43a4 --> 1502a238_61f0_9afa_8c3c_71d2bb769820
  799ac4a1_7d08_dd24_f075_2bfd21b8092b["prefixIdentifiers.ts"]
  799ac4a1_7d08_dd24_f075_2bfd21b8092b --> 1502a238_61f0_9afa_8c3c_71d2bb769820
  e4b641cd_cedf_fcbc_ccab_c4e184e0c140["compileScript.spec.ts"]
  e4b641cd_cedf_fcbc_ccab_c4e184e0c140 --> 1502a238_61f0_9afa_8c3c_71d2bb769820
  df0a1012_59c3_28fb_722a_df24d7f58ebd["prefixIdentifiers.spec.ts"]
  df0a1012_59c3_28fb_722a_df24d7f58ebd --> 1502a238_61f0_9afa_8c3c_71d2bb769820
  f81550a3_d9b1_086b_f23b_8dedde7a563e["codegen.spec.ts"]
  f81550a3_d9b1_086b_f23b_8dedde7a563e --> 1502a238_61f0_9afa_8c3c_71d2bb769820
  style 1502a238_61f0_9afa_8c3c_71d2bb769820 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import { CompilerOptions, CompiledResult } from 'types/compiler'
import { SFCDescriptor } from './parseComponent'

export interface StartOfSourceMap {
  file?: string
  sourceRoot?: string
}

export interface RawSourceMap extends StartOfSourceMap {
  version: string
  sources: string[]
  names: string[]
  sourcesContent?: string[]
  mappings: string
}

export interface TemplateCompiler {
  parseComponent(source: string, options?: any): SFCDescriptor
  compile(template: string, options: CompilerOptions): CompiledResult
  ssrCompile(template: string, options: CompilerOptions): CompiledResult
}

export const enum BindingTypes {
  /**
   * returned from data()
   */
  DATA = 'data',
  /**
   * declared as a prop
   */
  PROPS = 'props',
  /**
   * a local alias of a `<script setup>` destructured prop.
   * the original is stored in __propsAliases of the bindingMetadata object.
   */
  PROPS_ALIASED = 'props-aliased',
  /**
   * a let binding (may or may not be a ref)
   */
  SETUP_LET = 'setup-let',
  /**
   * a const binding that can never be a ref.
   * these bindings don't need `unref()` calls when processed in inlined
   * template expressions.
   */
  SETUP_CONST = 'setup-const',
  /**
   * a const binding that does not need `unref()`, but may be mutated.
   */
  SETUP_REACTIVE_CONST = 'setup-reactive-const',
  /**
   * a const binding that may be a ref.
   */
  SETUP_MAYBE_REF = 'setup-maybe-ref',
  /**
   * bindings that are guaranteed to be refs
   */
  SETUP_REF = 'setup-ref',
  /**
   * declared by other options, e.g. computed, inject
   */
  OPTIONS = 'options'
}

export type BindingMetadata = {
  [key: string]: BindingTypes | undefined
} & {
  __isScriptSetup?: boolean
}

Domain

Dependencies

Frequently Asked Questions

What does types.ts do?
types.ts is a source file in the vue codebase, written in typescript. It belongs to the CompilerSFC domain.
What does types.ts depend on?
types.ts imports 3 module(s): SFCDescriptor, compiler, parseComponent.ts.
What files import types.ts?
types.ts is imported by 9 file(s): codegen.spec.ts, compileScript.spec.ts, compileScript.ts, compileTemplate.ts, cssVars.ts, parse.ts, parseComponent.ts, prefixIdentifiers.spec.ts, and 1 more.
Where is types.ts in the architecture?
types.ts is located at packages/compiler-sfc/src/types.ts (domain: CompilerSFC, directory: packages/compiler-sfc/src).

Analyze Your Own Codebase

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

Try Supermodel Free