Documentation
¶
Overview ¶
Package tscode is the TypeScript/Vue backend for `sf code`. Extraction is line/block-based (there is no good pure-Go TS parser), so it is deliberately approximate but covers what a structural read needs: imports, top-level declarations, interface/type/enum members, and — for Vue SFCs — props, emits, models, the stores and API calls used, and the components rendered.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type TSFile ¶
type TSFile struct {
File string `json:"file"`
Lang string `json:"lang"` // ts | vue
Component string `json:"component,omitempty"` // .vue only
Imports []string `json:"imports,omitempty"` // module specifiers
Props []string `json:"props,omitempty"` // .vue defineProps keys
Emits []string `json:"emits,omitempty"` // .vue defineEmits keys
Models []string `json:"models,omitempty"` // .vue defineModel names
Stores []string `json:"stores,omitempty"` // .vue composables/stores used (useXStore)
APICalls []string `json:"api_calls,omitempty"` // .vue client.* / axios.* calls
Components []string `json:"components,omitempty"` // .vue components used in <template>
Types []TSType `json:"types,omitempty"` // interface/type/enum with members
Symbols []TSSymbol `json:"symbols"` // const | function | class
}
TSFile is the structural summary of a TypeScript / Vue source file.
Click to show internal directories.
Click to hide internal directories.