Closed
Description
openedon May 20, 2022
For CI builds we should explore the use of a fast transpiler, like SWC or esbuild. This would enable use to run (blocking) transpile, then in parallel run tests and TS type checking.
SWC transpile command: npx swc --config-file .swcrc src --copy-files --out-dir out
The joh/swc
-branch has some changes that explore to use SWC for this. TODOs
- support for AMD - SWC just does that, great!
- we heavily rely on TS decorators for our injection story and need that to be supported. Good news is that latest SWC 1.2.186 has this fixed
- SWC doesn't hoist const enums swc/issues/3648 which isn't ideal for perf but also exposes some cyclic module dependencies that we have. We need to fix
- Cyclic dependency:
vs/workbench/contrib/markers/browser/constants
andvs/workbench/contrib/markers/browser/markersTreeViewer
#150291 - Cyclic dependency:
vs/editor/common/languages
andvs/editor/common/tokenizationRegistry
#150176 - Cyclic dependency:
vs/editor/common/viewLayout/lineDecorations
andvs/editor/common/viewLayout/viewLineRenderer
#150177 - Cyclic dependency:
vs/workbench/contrib/tasks/common/tasks
andvs/workbench/contrib/tasks/common/taskService
#150178
- Cyclic dependency:
- The
--copy-files
flag doesn't seem to copy JS files (unclear if that's because they are compile-ignored or always seen as compilable resource) - Workaround
export import
bug swc/issues/4481 - Local require-function is missing from AMD modules, swc/issues/4718
- Using a namespace before its declaration fails, swc/issues/4897
- Issue with import-require mixing, either avoid or wait for
import foo = require
should be normal AMD dependency swc-project/swc#4898 - Static factory function in decorated class uses un-decorated ctor swc-project/swc#4899
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment