Converting React.createElement back to JSX
  • TypeScript 100%
Find a file
2023-08-12 01:29:27 +01:00
.vscode version bump & vscode tsdk 2023-08-12 00:15:36 +01:00
src fix imports named '_' 2023-08-12 01:29:27 +01:00
.gitignore Initial Commit 2022-09-25 20:52:31 +01:00
package.json version bump & vscode tsdk 2023-08-12 00:15:36 +01:00
pnpm-lock.yaml Add JSX Runtime and React Native support & QOL features (#3) 2023-08-12 00:13:52 +01:00
README.md Add JSX Runtime and React Native support & QOL features (#3) 2023-08-12 00:13:52 +01:00

JSX Reconstructor

This project was made with the intention of turning compiled React code back into JSX.

For example,

const x = React.createElement("div", null, "Hello, World!");

Should become:

const x = <div>Hello, World!</div>;

Caution!

This code is extremely shit and WIP. Please do give it a try and create an issue if you find any problems! Please provide some example code that I can work with to diagnose the issue. Thanks :)

Usage

  1. npm install
  2. Create a folder called input and place your .js files in there.
  3. Run npm run start

Copyright © 2023, https://github.com/MeguminSama & https://github.com/vftable