Use Babel to transform JSX instead of TypeScript #494
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is another attempt to set up our build pipeline so we can try out lingui, or any of the other i10n libraries that use babel plugins to transform/collect strings in JSX. See #488 for rationale on why this needs to be done.
Instead of migrating away from ts-jest like the previous attempt (#492) tried to do, this PR attempts to fix ts-jest via kulshekhar/ts-jest#1004.
Notes
I tried disabling type checking in ts-jest to see if tests would run faster, but they didn't, which was surprising, since it vastly speeds up our webpack side of things. Odd.
This moves our build and test TypeScript compiler options to a new
tsconfig.build.json
file.To do
--no-cache
from thetest:watch
target."jsx": "react"
intsconfig.json
so that we get lint errors when we don't importReact
for anything with JSX in it, but change it topreserve
in our actual build pipeline.