Skip to content

Commit

Permalink
Merge branch 'patternfly:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
wise-king-sullyman authored Dec 5, 2023
2 parents aec6903 + 070321a commit 35a958e
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions packages/module/scripts/writeClassMaps.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,17 @@ function writeIndex(fileName) {
}
}

function isNotTS(file) {
const isTS = file.endsWith('.ts');
const isNotDeclaration = !file.endsWith('.d.ts');

if (isTS && isNotDeclaration) {
return false;
}

return true;
}

/**
* @param {any} classMaps Map of file names to classMaps
*/
Expand All @@ -65,10 +76,10 @@ function writeClassMaps(classMaps) {
copyFileSync(file, join(outDir, outPath));

ensureDirSync(esmDistDir);
copySync(outDir, esmDistDir);
copySync(outDir, esmDistDir, { filter: isNotTS });

ensureDirSync(jsDistDir);
copySync(outDir, jsDistDir);
copySync(outDir, jsDistDir, { filter: isNotTS });
});

// eslint-disable-next-line no-console
Expand Down

0 comments on commit 35a958e

Please sign in to comment.