From 5cd5085f0534f8fd3ba0e93180a50fc7ce00f1ec Mon Sep 17 00:00:00 2001 From: Philipp Kunz Date: Wed, 4 Dec 2024 23:14:36 +0100 Subject: [PATCH] fix(TsWatch): Fix reloading issue for tsfolder changes in element mode. --- changelog.md | 5 +++++ ts/00_commitinfo_data.ts | 2 +- ts/tswatch.classes.tswatch.ts | 2 +- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/changelog.md b/changelog.md index 2a78c88..77e7905 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,10 @@ # Changelog +## 2024-12-04 - 2.0.34 - fix(TsWatch) +Fix reloading issue for tsfolder changes in element mode. + +- Adjusted the function call from 'this.typedserver.reload()' to 'bundleAndReloadElement()' to ensure proper bundle handling in 'element' mode. + ## 2024-12-04 - 2.0.33 - fix(core) Improve async handling in TsWatch class for element and website modes diff --git a/ts/00_commitinfo_data.ts b/ts/00_commitinfo_data.ts index 4cfa27f..601b17a 100644 --- a/ts/00_commitinfo_data.ts +++ b/ts/00_commitinfo_data.ts @@ -3,6 +3,6 @@ */ export const commitinfo = { name: '@git.zone/tswatch', - version: '2.0.33', + version: '2.0.34', description: 'watch typescript projects during development' } diff --git a/ts/tswatch.classes.tswatch.ts b/ts/tswatch.classes.tswatch.ts index cb93b66..dcc02d8 100644 --- a/ts/tswatch.classes.tswatch.ts +++ b/ts/tswatch.classes.tswatch.ts @@ -93,7 +93,7 @@ export class TsWatch { functionToCall: async () => { logger.log('info', `building ${tsfolder}`); await smartshellInstance.exec(`(cd ${paths.cwd} && npm run build)`); - await this.typedserver.reload(); + await bundleAndReloadElement(); }, timeout: null, })