Skip to content

Commit 6d72f03

Browse files
authored
fix(package/cli): ESM import path for optional deps in watch mode (#1855)
1 parent 3e5cd7d commit 6d72f03

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

.changeset/cold-parents-eat.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@gqty/cli': patch
3+
---
4+
5+
ESM import path for optional deps in watch mode

packages/cli/src/commands/default.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,9 @@ export const addCommand = (command: Command) => {
181181
// Watch mode
182182
if (options.watch) {
183183
const { printSchema } = await import('graphql');
184-
const { FasterSMA: SMA } = await import('trading-signals/dist/SMA/SMA');
184+
const { FasterSMA: SMA } = await import(
185+
'trading-signals/dist/SMA/SMA.js'
186+
);
185187
const { default: throttle } = await import('lodash-es/throttle.js');
186188
const {
187189
default: { isMatch },

0 commit comments

Comments
 (0)