This tutorial on using TypeScript in Construct has been moved to the official manual, in the 'Scripting' section's guides. You can now find the latest documenta...
Is it possible to make Construct to allow me to write imports like:
import Globals from "./globals"
instead of:
import Globals from "./globals.js";
without .js at the end.
When I'm working on TypeScript projects all imports usually omit file extension. This is a bit anoying to manualy change it all the time. I'll see if I can configure my IDE to add .js at the end. But I've been working more than 5 years with TypeScript and never ever I've added any extensions in the imports. Also IDE auto insert imports, and they don't have extensions
TypeScript needs to generate JavaScript that refers to a filename like "./globals.js", because that's how it works in the browser. You can configure TypeScript however you like, so long as it outputs that. I think I saw that TypeScript 5.7 is going to be adding some new options around this.