Closed Kcin1993 closed 1 year ago
@Kcin1993 Hi, thank you for your comment.
Yes, as you mentioned it is required to add .js
even though the file is .ts
.
It is the problem of Tyepscript + Nodejs ESM
.
Related https://github.com/TypeStrong/ts-node/issues/1777 https://stackoverflow.com/questions/63742790/unable-to-import-esm-ts-module-in-node https://www.typescriptlang.org/docs/handbook/esm-node.html https://github.com/nodejs/node/issues/46006
I think it could be solved with next Typescript version (Typescript v5).
Thanks for your information 👍
Hi, thank you for creating this template.
I noticed that the files imported in
web/index.ts
imported.js
file, while the files in the directory, such asshopify.ts
,product-creator.ts
, andgdpr.ts
all have a.ts
extension. What is the reason for this?Also, I noticed that if I remove the
.js
in the import path, it causesweb/index.ts
to fail to import the files properly.Thank you again for creating the TypeScript version of this app.