Skip to content

Commit 1780895

Browse files
committed
add removing data.ts for artifacts template
1 parent 39a4ee5 commit 1780895

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

packages/create-llama/helpers/typescript.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,14 @@ const installLlamaIndexServerTemplate = async ({
7575
rename: () => "data.ts",
7676
});
7777
}
78+
79+
// Simplify use case code
80+
if (useCase === "artifacts") {
81+
// Artifact use case doesn't use index.
82+
// We don't need data.ts, generate.ts
83+
await fs.rm(path.join(root, "src", "app", "data.ts"));
84+
// TODO: Remove generate index in generate.ts and package.json if possible
85+
}
7886
};
7987

8088
const installLegacyTSTemplate = async ({

0 commit comments

Comments
 (0)