Skip to content

[SG-33302] Upgrade all client packages to use the latest version of the JSX transform

Warren Gifford requested to merge contractors/SG-33302.6 into main

Created by: gitstart-sourcegraph

Description

  • Upgrade to the latest version of the JSX transform in all packages with following steps:

    • Update babel.config.js to use new @babel/preset-react runtime
    • Update all tsconfig.json to use "jsx": "react-jsx"
    • Execute: npx react-codemod update-react-imports ./client --parser=tsx
    • Fix lint/format errors
  • Note: React codemod adds import * as React from 'react' in files which are using React APIs via React.* form, it requires some extra works to convert React.react_api to import { react_api } from 'react' (already did that for client/branded package). it would be great if we have our own codemod to do that transform

Test plan

Make sure all checks are passed in CI

Refs

App preview:

Check out the client app preview documentation to learn more.

Merge request reports

Loading