mirror of
https://github.com/zoriya/v10.git
synced 2026-08-08 23:27:58 +00:00
feat(site): generated multipart component api reference (#468)
This commit is contained in:
@@ -29,7 +29,7 @@ export function extractCore(filePath: string, program: ts.Program, componentName
|
||||
let description: string | undefined;
|
||||
|
||||
if (propsExport?.type instanceof tae.ObjectNode) {
|
||||
const formatted = formatProperties(propsExport.type.properties);
|
||||
const formatted = formatProperties(propsExport.type.properties, ast.exports);
|
||||
props = Object.entries(formatted).map(([name, def]) => ({
|
||||
name,
|
||||
...def,
|
||||
@@ -40,7 +40,7 @@ export function extractCore(filePath: string, program: ts.Program, componentName
|
||||
// Extract state
|
||||
let state: ExtractedProp[] = [];
|
||||
if (stateExport?.type instanceof tae.ObjectNode) {
|
||||
const formatted = formatProperties(stateExport.type.properties);
|
||||
const formatted = formatProperties(stateExport.type.properties, ast.exports);
|
||||
state = Object.entries(formatted).map(([name, def]) => ({
|
||||
name,
|
||||
...def,
|
||||
|
||||
Reference in New Issue
Block a user