From 2276e57978556d478149f2914cab91d89fc24298 Mon Sep 17 00:00:00 2001 From: Simon Farshid Date: Sat, 30 Nov 2024 12:04:01 -0800 Subject: [PATCH] fix: cjs builds (#1231) fixes #1230 --- .changeset/chilled-boats-thank.md | 7 +++++++ packages/tsbuildutils/src/index.ts | 6 +++++- 2 files changed, 12 insertions(+), 1 deletion(-) create mode 100644 .changeset/chilled-boats-thank.md diff --git a/.changeset/chilled-boats-thank.md b/.changeset/chilled-boats-thank.md new file mode 100644 index 000000000..f31c2cb01 --- /dev/null +++ b/.changeset/chilled-boats-thank.md @@ -0,0 +1,7 @@ +--- +"@assistant-ui/react-markdown": patch +"@assistant-ui/react-trieve": patch +"@assistant-ui/react": patch +--- + +fix: cjs builds diff --git a/packages/tsbuildutils/src/index.ts b/packages/tsbuildutils/src/index.ts index dd9b1baff..b786754cf 100644 --- a/packages/tsbuildutils/src/index.ts +++ b/packages/tsbuildutils/src/index.ts @@ -45,7 +45,11 @@ const transpileTypescript = async () => { splitting: false, silent: true, - esbuildPlugins: [esbuildPluginFilePathExtensions()], + esbuildPlugins: [ + esbuildPluginFilePathExtensions({ + cjsExtension: "js", + }), + ], }); };