This repository was archived by the owner on Oct 5, 2021. It is now read-only.
This repository was archived by the owner on Oct 5, 2021. It is now read-only.
Implement instrumentation as a TypeScript Compiler Transformer #41
Closed
Description
Compiler transformers introduced in microsoft/TypeScript#13764, and they seem to allow modifying the AST directly rather than updating the source code. This should improve performance, though, it seems like we will have to rewrite the instrumentor to support that.
Seems like both awesome-typescript-loader and ts-loader have support for custom transformers.
Here are a few example of what a custom transformer looks like (source):
https://github.com/longlho/ts-transform-system-import
https://github.com/longlho/ts-transform-img
https://github.com/longlho/ts-transform-react-intl
https://github.com/longlho/ts-transform-css-modules-transform