-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
build ts to js #8
Comments
@ak1103dev have you check the version of node is is it support for typescript? |
Greetings. If I'm not wrong, we can add For example: {
"compilerOptions": {
"baseUrl": "src",
"paths": {
"app/*": ["app/*"],
"config/*": ["app/_config/*"]
},
} Reference |
Greetings, again. After digging deeper, it can be said that adding The ProblemTypescript compiler's expected behavior of not mapping import aliases was a growing debate on it's repository (#10866) but was closed under working as intended. Mapping import aliases by The objective of this repository is to make use of Typescript with NodeJS and so features like import aliases to improve productivity, readability and maintainability of the codebase. So, using I can see the use of node-ts-boilerplate/package.json Line 10 in aa67acf
Possible SolutionI was able to solve this issue and make the production (build) version running without any errors with Webpack using Caveats (or not?)PerformanceSince Webpack is used to generate the production bundle, it crunches everything in a single (and possibly minified) file which then can be executed using And, if we think of a scenario where @ak1103dev, please let me know your thoughts on this. I would be glad to make a PR using the Webpack solution. |
@kasipavankumar the script is not error for running. but I want to build ts to js then run start js file for production. |
Yes, sir. I get your point. I've tried to reproduce the issue locally. There were two issues I've encountered:
So, I used Webpack to correctly resolve the relative imports at the build time. |
I use absolute path for import library or utilities.
When I build ts to js, it cannot run js file because import with absolute path not found.
I think use webpack for build ts to js
The text was updated successfully, but these errors were encountered: