ogl-typescript
ogl-typescript copied to clipboard
Import .js extensions / update vite to latest to support .js extensions (don't break examples)
Hello, I run webpack-free environments for my typescript using babel to compile to JS and es-module-shims to support imports maps so I can load node_modules directly into the browser with no build step / faster TS project compile times. Unfortunately browsers don't know what to do without .js extensions on esm imports.
Thankfully just about everything else can handle .js imports even when their sources are .ts, including vite starting in 2.7 beta ( https://github.com/vitejs/vite/issues/5539 ), which this repo's examples are built with.
The current version on the master branch is outdated vite, and cannot handle .js extensions, so I have updated / run the examples for testing purposes and cannot find any issues.
Running npm dev
should now report
... vite v2.9.14 dev server ...
Let me know what you think.
V/r, Jon Crowder
looks like I forgot to push the last commit where I updated vite. I'll do this this afternoon and update here
I have updated vite version in ogl-typescript package.json to 2.9.14 in this pull request. All npm run * commands should function properly now.