Skip to content

Commit

Permalink
chore: remove vetur type generator (vueComponent#7517)
Browse files Browse the repository at this point in the history
  • Loading branch information
extclp committed Apr 22, 2024
1 parent 23c620e commit 48a3ceb
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 57 deletions.
8 changes: 0 additions & 8 deletions antd-tools/generator-types/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import { genWebTypes } from './web-types';
import { outputFileSync, readFileSync } from 'fs-extra';
import type { Options, VueTag } from './type';
import { getComponentName, normalizePath, toKebabCase } from './utils';
import { genVeturAttributes, genVeturTags } from './vetur';
import { flatMap } from 'lodash';

async function readMarkdown(options: Options): Promise<Map<String, VueTag>> {
Expand Down Expand Up @@ -78,13 +77,6 @@ export async function parseAndWrite(options: Options): Promise<Number> {
const tagsFromTypings = await readTypings(options);
const tags = mergeTags([tagsFromMarkdown, tagsFromTypings]);
const webTypes = genWebTypes(tags, options);
const veturTags = genVeturTags(tags);
const veturAttributes = genVeturAttributes(tags);
outputFileSync(join(options.outputDir, 'tags.json'), JSON.stringify(veturTags, null, 2));
outputFileSync(
join(options.outputDir, 'attributes.json'),
JSON.stringify(veturAttributes, null, 2),
);
outputFileSync(join(options.outputDir, 'web-types.json'), JSON.stringify(webTypes, null, 2));
return tags.length;
}
Expand Down
19 changes: 0 additions & 19 deletions antd-tools/generator-types/src/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,25 +34,6 @@ export type VueTag = {
description?: string;
};

export type VeturTag = {
description?: string;
attributes: string[];
};

export type VeturTags = Record<string, VeturTag>;

export type VeturAttribute = {
type: string;
description: string;
};

export type VeturAttributes = Record<string, VeturAttribute>;

export type VeturResult = {
tags: VeturTags;
attributes: VeturAttributes;
};

export type Options = {
name: string;
path: PathLike;
Expand Down
30 changes: 0 additions & 30 deletions antd-tools/generator-types/src/vetur.ts

This file was deleted.

0 comments on commit 48a3ceb

Please sign in to comment.