From d470a1f352345f6712c64779317aaf9286c5490e Mon Sep 17 00:00:00 2001 From: ysm-dev Date: Sat, 9 Nov 2024 11:08:43 +0900 Subject: [PATCH] fix: add filter to remove falsy values in generateExports --- build/generateExports.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/build/generateExports.ts b/build/generateExports.ts index 7760487a..7ff68dd3 100644 --- a/build/generateExports.ts +++ b/build/generateExports.ts @@ -1,7 +1,7 @@ import { readFile, writeFile } from "fs/promises"; import { glob } from "glob"; -import { drop, map, not, pipe, reduce } from "../src/index"; +import { drop, filter, identity, map, not, pipe, reduce } from "../src/index"; const SOURCE_DIR = "./src"; const OUTPUT_DIR = "./dist"; @@ -54,6 +54,7 @@ async function generateExports() { const subPathExports = pipe( fileNames, + filter(identity), map((name) => { const conditionalSubPaths = { types: `${TYPES_ROOT_DIR}/${name}.d.ts`,