@steuchs/qsrc2react
v0.0.16
Published
Experimental prototype for covererting qsrc-code to react-code. Do not use unless explicitly told to do so by the author!
Downloads
26
Readme
Setup
- Make sure you have Node.js and npm installed.
- Run
npm iin the terminal in the root folder to install the dependencies. - Install antlr4 (https://github.com/antlr/antlr4-tools might be handy).
- Run
antlr4 -Dlanguage=JavaScript -visitor qsrcLexer.g4insrc\antlr - Run
antlr4 -Dlanguage=JavaScript -visitor qsrcParser.g4insrc\antlr
Create Binary
This guide assumes that you're using Node 22.7.0. Check here if you're using another version: https://nodejs.org/api/single-executable-applications.html
Windows
- Run
npm run buildin the root folder. This will use webpack to create the file dist/blob.js - Run
node --experimental-sea-config sea-config.jsonto create sea-prep.blob - Run
node -e "require('fs').copyFileSync(process.execPath, 'QSRC2TW.exe')"to copy and rename your node.exe to QSRC2TW.exe - Run
powershell npx postject hello.exe NODE_SEA_BLOB sea-prep.blob --sentinel-fuse NODE_SEA_FUSE_fce680ab2cc467b6e072b8b5df1996b2to append sea-prep.blob to QSRC2TW.exe - Run
npx webpack --config './webpackProcessor.config.cjs'to create task_processor.js in the folder dist - Copy QSRC2TW.exe and task_processor.js (the one from the dist-folder) to where you need these files.
