From a679776f89ea71cd6614274fe43bf28af8fa4b62 Mon Sep 17 00:00:00 2001 From: Judson Cairo Date: Thu, 15 Aug 2024 15:32:17 -0300 Subject: [PATCH] Fixed chatwoot translation files on build --- tsup.config.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tsup.config.ts b/tsup.config.ts index f1399a13..2450b52f 100644 --- a/tsup.config.ts +++ b/tsup.config.ts @@ -1,3 +1,5 @@ +import { cpSync } from 'node:fs'; + import { defineConfig } from 'tsup'; export default defineConfig({ @@ -8,6 +10,9 @@ export default defineConfig({ clean: true, minify: true, format: ['cjs', 'esm'], + onSuccess: async () => { + cpSync('src/utils/translations', 'dist/translations', { recursive: true }); + }, loader: { '.json': 'file', },