mirror of
https://github.com/primefaces/primevue.git
synced 2025-05-09 00:42:36 +00:00
prettier warnings fixed
This commit is contained in:
parent
f060c3a940
commit
ee8e35aabd
7 changed files with 22 additions and 11 deletions
|
@ -17,6 +17,7 @@ const fileModules = {},
|
|||
veturAttributes = {};
|
||||
|
||||
const files = fs.readdirSync(componentPath);
|
||||
|
||||
files.forEach((file) => {
|
||||
const { name } = path.parse(file);
|
||||
|
||||
|
@ -123,11 +124,13 @@ const createWebTypes = (component) => {
|
|||
|
||||
const createVeturTags = (component) => {
|
||||
const attributes = [];
|
||||
|
||||
if (component.props) {
|
||||
component.props.forEach((comp) => {
|
||||
attributes.push(comp.name);
|
||||
});
|
||||
}
|
||||
|
||||
if (attributes.length > 0) {
|
||||
veturTags[component.name] = {
|
||||
description: component.description,
|
||||
|
@ -154,10 +157,13 @@ Object.keys(fileModules).forEach((p) => {
|
|||
});
|
||||
|
||||
const webTypesJson = JSON.stringify(webTypes, null, 2);
|
||||
|
||||
fs.writeFileSync(path.resolve(distDir, 'web-types.json'), webTypesJson);
|
||||
|
||||
const veturTagsJson = JSON.stringify(veturTags, null, 2);
|
||||
|
||||
fs.writeFileSync(path.resolve(distDir, 'vetur-tags.json'), veturTagsJson);
|
||||
|
||||
const veturAttributesJson = JSON.stringify(veturAttributes, null, 2);
|
||||
|
||||
fs.writeFileSync(path.resolve(distDir, 'vetur-attributes.json'), veturAttributesJson);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue